Start by navigating to our ansible roles directory:
$ cd ansible/roles
This directory should contain the helloworld and nodejs directories, with the configurations that we created previously in Chapter 3, Treating Your Infrastructure as Code. We are now going to create our Jenkins role with the ansible-galaxy command:
$ ansible-galaxy init jenkins
We are now going to edit the task definition for this new role by editing the file: jenkins/tasks/main.yml. Open up the file with your favorite text editor.
The goal of our task is to install and start Jenkins. In order to do this, since we are on a Linux-based operating system (AWS Amazon Linux, in our case), we are going to install an RPM package through ...