Downloading and installing Jenkins
1. Install java on vm
Step 1: To ensure your system is up to date, open a terminal window and execute the following command:
apt-get update -y
Step 2: To install Java, which is a prerequisite for Jenkins, you can use the following command in your terminal:
apt install openjdk-11-jre
Step 3: Verify the version of java by executing the following command.
java -version
2. Downloading Jenkins
Step 1: Below command is used for downloading and saving the Jenkins repository key to a keyring file named jenkins-keyring.asc.
curl -fsSL https://pkg.jenkins.io/debian/jenkins.io.key | sudo tee \ /usr/share/keyrings/jenkins-keyring.asc > /dev/null
Step 2: After making the repository URL into a file named jenkins.list in the /etc/apt/sources.list.d/ directory, the bellow command puts the Jenkins repository to the list of package sources.
echo deb [signed-by=/usr/share/keyrings/jenkins-keyring.asc] \ https://pkg.jenkins.io/debian binary/ | sudo tee \ /etc/apt/sources.list.d/jenkins.list > /dev/null
Step 3: Update the packages again using the below command.
apt-get update -y
Install Jenkins on Amazon EC2: Step-by-Step GuidePrerequisites
Jenkins configuration in the EC2 instance on the Amazon Web Service Platform includes all steps in detail, which helps the user easily set up your Jenkins tools on the EC2 instance for continuous integration and continuous development. Nowadays, Jenkins has become a more popular tool as compared to others, and it is open source. It is free, and it is lightweight. Jenkins using the 8080 port. Jenkins code is available for everyone to contribute and add more features to this tool. It has a strong community and it has a number of plugins to do any type of work related to continuous integration and continuous development.
Prerequisites
- We need to set up an Amazon account.
- Amazon Linux instance.