Let’s do installation and configuration of GoCD
GoCD is an open source system. GoCD is continuous delivery and automation system. GoCD helps you to streamline and automate your BTR (build, test and release) cycle for perfect and continuous delivery of the product. With the help of its sequential and parallel execution, it configures the dependencies for on demand deployment and faster feedback. You can model complex workflows easily. You can visualize a complex workflow end to end in real-time by using its value stream map.
GoCD compares two builds and let you deploy the version of your choice. GoCD executes tests in various frameworks and languages. It provides cross-platform and parallel execution. GoCD reporting tells you the exact changeset and where the test broke which helps in debugging and fixing. There are various plugins and extensions available, you can use them. You can also create your own plugin.
GoCD does not restrict its installation to any specific operating system (OS). You can use any operating system (OS) of your choice; however, the installation steps would vary according to the choice of operating system.
In this first part of this tutorial, you will learn about prerequisites for GoCD, hardware configurations recommended for GoCD, how to add user, how to assign root privileges to a user, how to update CentOS, how to install epel-release, how to install git, how to install nano-editor, how to install Java and how to do security group settings necessary for GoCD server.
Prerequisites:
Getting started:
Add a User with Root Privileges:
In the first step, you will add a new user and give it sudo privileges. Sudo privileges will allow this username to make administrative changes on system when required. This user will be used to login from via SSH for everyday use. Once you have added this user, to keep your server secure from various attacks, you will disable the remote root access to root user.
# adduser aareez
where “aareez” can be any username of your choice.
# passwd aareez
Now set your desired password and retype your desired password, then hit Enter key. To confirm the data is correct, type ‘Y’ and hit Enter key.
# visudo
Sometimes by default the second line %wheel ALL=(ALL:ALL) ALL is commented (starting with hash #), due to which even after adding username to sudoers, it gives error on using sudo. To prevent this issue, if this line starts with ‘#’ sign, remove this symbol and save the changes by pressing Esc key, type 😡 and hit enter.
# usermod -aG wheel aareez
After execution of the above command, you can verify the membership for that group by executing the following command:
# groups aareez
Your username has been successfully added to sudoers group and it is able to execute any root command.
# su - aareez
You can see that you have been logged in from your new account now. If you want to verify this, you can use the command below:
# whoami
Update CentOS 7 System:
Before proceeding with installation of any kind of package, use the following command to update your CentOS system. To execute this command, remember to login from non-root user with sudo privileges.
# sudo yum -y update
Now you have successfully updated your CentOS system.
Install epel-release:
# sudo yum install epel-release
# sudo yum update -y && sudo shutdown -r now
Install Git:
You will need to install Git to get clone of Let’s Encrypt SSL from Github. To install git, follow the steps below:
# sudo yum -y install git
Install nano text editor:
You will need to install nano editor to edit files.
# sudo yum -y install nano
Install Java:
GoCD requires Java version 8. You are allowed to use Oracle Java or OpenJDK. The steps for installation may vary. In this tutorial, I will use Java 8 form OpenJDK because it is already available in yum package by default.
# sudo yum -y install java-1.8.0-openjdk-devel
# java -version
# readlink -f $(which java)
You will see the following output.
/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.161-0.b14.el7_4.x86_64/jre/bin/java |
# echo “export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.151-5.b12.el7_4.x86_64” >> ~/.bash_profile |
# echo “export JRE_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.151-5.b12.el7_4.x86_64/jre” >> ~/.bash_profile |
# source ~/.bash_profile
# echo $JAVA_HOME
In this first part of this tutorial, you have learnt about prerequisites for GoCD, hardware configurations recommended for GoCD, how to add user, how to assign root privileges to a user, how to update CentOS, how to install epel-release, how to install git, how to install nano-editor, how to install Java and how to do security group settings necessary for GoCD server. In the next part, you will learn about installation of GoCD and configuration of GoCD along with installation of SSL using Let’s Encrypt. For the next steps to complete installation, you will need to follow steps in part 2. Click here for part 2.
If you are living in a digital world you must know how to protect your…
Software Development Life Cycle Model, also known as SDLC or Software Development Process, is base…
Go, often referred to as golang is a modern open-source programming language created by Google…
Torque published an article on October 18, 2016, about WordPress statistics. According to this article,…
PostgreSQL, often known simply as Postgres, is an open-source general-purpose object-relational database management system. In…
SEO is free as well as paid. To achieve SE ranking, money is not enough.…