This month I'm working on a little project and the first thing I want to do is set up my "continuous delivery" pipeline. Because I'm most familiar with Jenkins, I will use it to design my pipeline.
First, I'll spin up a small instance on Digital Ocean. It's very easy to use and very developer friendly.
Once the instance is up and you have logged into that instance, it is as easy as the running these 4 commands:
wget -q -O - https://pkg.jenkins.io/debian/jenkins-ci.org.key | sudo apt-key add -
sudo sh -c 'echo deb http://pkg.jenkins.io/debian-stable binary/ > /etc/apt/sources.list.d/jenkins.list'
sudo apt-get update
sudo apt-get install jenkins
Once the installation is complete, we will want to enable traffic to port 80/8080. Since this is a development jenkins, I will use iptables to route traffic.
iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8080
iptables -t nat -I OUTPUT -p tcp -d 127.0.0.1 --dport 80 -j REDIRECT --to-ports 8080
Now, open the browser and visit the jenkins server (the ip address given to you by Digital Ocean).
Follow the instructions listed on the pages that follow and you'll be up and running with a jenkins server.