Author Archives: daniel.kreling

I found two ways to configure the /etc/resolv.conf file to prevent it to be overridden by the system.

  1. Edit the base file under the resolv.conf.d file
sudo vim /etc/resolvconf/resolv.conf.d/base

and then add the nameservers to the file:


lastly, update resolvconf:

sudo resolvconf -u

2. Install dnsmasq and edit /etc/dnsmasq.conf to add the nameservers you want.

sudo apt install dnsmasq
vim /etc/dnsmasq.conf

Then restart the network services:

sudo service dnsmasq restart and
sudo service network-manager restart

You should be all set now.





Static IP config with netplan (ubuntu)

If you use a modern Ubuntu distribution (the latest 18.04 LTS or 17.XX), you might have noticed that the package to configure the network changed.

Ubuntu changed to Netplan, that is more modern and relatively simpler to use. The file configuration for a static IP should be as follows.

# cat /etc/netplan/01-netcfg.yaml
 version: 2
 renderer: networkd
 dhcp4: no
 addresses: [YOUR.STATIC.IP.ADDRESS/24]
 gateway4: X.X.X.X
 addresses: [YY.YY.YY.YY,]

Reference: I extracted the following information from

Please visit the link above for more information (including the original /etc/network/interfaces format of the eth0 interface before the transition to netplan).


Install Silversearcher-ag on Ubuntu

The Silversearcher tool is a super fast search tool that gives you rich information when searching for a string through all your files.

To install it:

sudo apt install silversearcher-ag

The Github project page:

You can find answers about why it is so fast, a chance to collaborate and other info there.


Git: Add ‘Signed-Off-By’ From Command Line

In order to append a Signed-off-by line with the author’s information.

In order to automatically append this line to the commit, append a ‘-s’ switch to the git commit command:

$ git commit -s

Just be sure your name and email are correct in the appended line, and you are done!

NOTE: In case your information is not correct, issue:

$ git config --global "Your Name"
$ git config --global ""


Git: basic tag commands

To get the repository’s tags issue:

$ git fetch --tags [branch_name]

To add a tag to the top commit:

$ git tag -a

Note: this will open an editor screen where you can insert a description message (similar to a commit)

To add a tag to a specific commit:

$ git tag -a [tag_name] [commit_hash]

To push a tag to remote:

$ git push [repo_name] --tags  # for all tags
$ git push [repo_name] [tag_name] # for a single tag named 'tag_name'

To merge a tagged commit:

$ git merge [tag_name]

See also: how to see the information of the repo’s branches from the CLI, including your tags in this post