Steps to use this TerraJenker rep.
-
Bring up a VM [Can be EC2 or any other VMs]. (Will automate this step soon in Terraform)
-
Clone this repo in the VM.
-
Run the Jenkins-Docker.sh file. This shell script will install Jenkins and Docker in your VM.
-
Once the script has executed successfully, copy the administrator password.
-
You can open Jenkins with the VM public IP and port 8080. Use the copied password and install the required plugins and sign in.
-
Once you have signed in, you can create a new pipeline with the JENKINSFILE that's available in the repo.
-
Ensure that you have saved you dockerhub credentials in Jenkins. You must also modify the JENKINSFILE to use your image tag.
-
Once the above step is completed, Run your build.
-
If everything is successful, you should open a new tab with the VM public IP and port 3000. You should be able to view something similar to the image below.
Reference:
- Devops Project | CI/CD Setup : https://www.youtube.com/watch?v=q3S_B5cX_6o&list=PLr5IlaMG846FinrEdWZmGQjt3s20zg6PI&index=1
- ToDo List App Github Repo used: https://github.com/dockersamples/todo-list-app.git

