GPG Key in Git - Get Your Every Commit Verified

This article is based on the contents of the Github’s documentation.

You will get your own verified badge on every git commits once you configure your GPG key with your VCS.

First things first, check your gpg version using this command:

1
gpg --version

Allow me to assume that you are on version 2.1.17 or greater.

Use this command to generate a GPG key:

1
gpg --full-generate-key

Choose the default for kind of key and give 4096 for key size, choose 0 for expiration time or up to your decision otherwise.

Hugo - Awesome Way to Enjoy Blogging as an Engineer

I have just finished migrating my blog from Ghost self-hosting to Hugo. I am more than happy to use: { framework: “Hugo”, hosting: “Firebase”, cicd: “CircleCI” }. I just wanted to share the full process of how I got it done, which was not a piece of cake. You see, it’s not a toy project, it’s real one. There are plenty of great resources available that explain how to setup Hugo, install Hugo themes, and so on. In this post, I will focus on the challenges I faced during this migration.

Deploy Your Web Apps in Just a Minute - Made with 💖 for Dockerists

As a software engineer or DevOps engineer, you may frequently encounter mundane tasks, such as setting up a new cloud environment for deploying your web apps or microservices.

With the following script though, you can eliminate this tedious process. Simply obtain the script, run it with bash, and you will have a complete environment with the latest stable versions of Docker, Docker Compose, and Nginx.

You might wanna convert it to an Ansible playbook. :)

How to Install Docker Engine (Not a Legacy Version!) on Ubuntu Bionic or Focal

In some cases, you may get stuck due to docker and docker compose version.

Let’s follow up on docker official documentation:

1
2
3
4
5
6
apt remove docker docker-engine docker.io containerd runc    # purging the legacy version if exists
apt install apt-transport-https ca-certificates curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
apt-key fingerprint 0EBFCD88
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
apt update && apt install docker-ce docker-ce-cli containerd.io

Very awesome! What about the docker-compose which is a pretty cool stuff?

How to Use Jenkins - A Basic Approach

Deploy your Jenkins instance first.

We are going to use password login for automatic deployment, note that it’s not the most secure way, but for simplicity for now.

CHANGE SSH PORT - FOR DESTINATION SERVER

1
sudo vim /etc/ssh/sshd_config

Find out the line #port 22 and uncomment it to change into port ${YOUR_NEW_SSH_PORT}, then reload the sshd service like so:

1
sudo systemctl restart sshd

One more additional step for firewall (ufw in Ubuntu, firewall-cmd in CentOS), but we will refer to tons of materials out there, instead of mentioning it here.