If you need to add additional
nameservers to your
resolv.conf because of DNS related issues, you'll want to use a package that manages the file at
/etc/resolv.conf. This is because on system restart, the file will be overwritten by other processes and you will lose any previous changes.
sudo apt update
sudo apt install resolvconf
Check if it is running
sudo systemctl status resolvconf
To intercept emails in specific environments such as development, testing, or staging, we need to write some logic to do so.
# This will be the email that live emails will be sent to
message.to = ['email@example.com']
# Set the cc and bcc to be nil to avoid sending out real emails
message.cc = nil
message.bcc = nil
# Change the from if you want a di...
If your logs ever start becoming too large to manage, a good way to rotate them is by using
logrotate on Ubuntu.
sudo apt install logrotate
Then create a file named after what your project is:
sudo vim /etc/logrotate.d/portfolio
You can rotate logs based off of file size or time intervals.
-c Create a new archive containing the specified items.
-r Like -c, but new entries are appended to the archive. Note that this only works on uncompressed archives stored in regular files. The -f option is required.
-t List archive contents to stdout.
-u Like -r, but new entries are added only if they have a modification date newer than the corresponding entry in the archive. Note that this only works on uncompressed archives stored in regular files....
We should install a version manager to keep our ruby versions and gems.
sudo apt-get install libgdbm-dev libncurses5-dev automake libtool bison libffi-dev
gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
curl -sSL https://get.rvm.io | bash -s stable
rvm install 2.5.1
rvm use 2.5.1 --default
You should create a swap f...
On a windows computer download Win32 Disk Imager and SD Card Formatter. First format the card with the quick format option, then use the imager to install a Debian image from here.
Turn off the Orange Pi and then insert the Micro SD Card. Boot it up and it should boot to that card. Try username as root and password 1234. Once loaded, type
I found myself in a bind with a PDF document that was 112 MB in size when I photo copied all my housing papers into PDF files and combined them into one pdf.
convert *.JPG papers.pdf
The file was impossible to email or even display in Google Drive due to its sheer size. I have found a work around to make it happen. Open the PDF you want to downsize in the Preview Mac OS X application.
You'll notice that when you go to the file -> export option, you only hav...
After uploading a bunch of user content to your AWS S3 Bucket, what do you do if you want to download all that information to back it up?
Luckily AWS has a CLI that we can use.
Follow the steps below to install the CLI using curl. Amazon's steps are found here.
curl "https://s3.amazonaws.com/aws-cli/awscli-bundle.zip" -o "awscli-bundle.zip"
Sometimes the Open SSH Server does not come enabled or installed by default on a clean installation. This short guide will show you how to get it one your machine.
Let's download the program.
sudo apt-get install openssh-server
Verify that it installed properly.
sudo service ssh status
If you want to modify any of the ports or settings in SSH, simply open the file and change what...
Pi Hole is an ad blocking service that uses your server as a DNS to filter out known ad sites and can even filter out pornographic and malicious sites.
Let's update and upgrade our packages.
sudo apt-get update && sudo apt-get upgrade -y
We will need to install git in order to download the Pi Hole repository.
sudo apt-get install git
Because your internal IP address can ...