---

- name: Install all package upgrades
  yum: name=* state=latest
  notify:
     - Restart server
     - Wait for server to restart

- name: Get OpenJDK 8 and other common dependencies
  yum: name={{item}} state=present
  with_items:
   - unzip
   - java-1.8.0-openjdk
   - git
   - curl
   - gnupg
   - mc
   - htop

# Create the jenkins user
- user: name=jenkins comment="Jenkins user" shell=/bin/bash state=present

# Not using the Ansible module 'authorized_key' as it's not working as documented
- name: Create .ssh folder
  file: path=/home/jenkins/.ssh state=directory mode=0700 owner=jenkins


---

- name: Install all package upgrades
  yum: name=* state=latest
  notify:
     - Restart server
     - Wait for server to restart

- name: Get OpenJDK 8 and other common dependencies
  yum: name={{item}} state=present
  with_items:
   - unzip
   - java-1.8.0-openjdk
   - git
   - curl
   - gnupg
   - mc
   - htop

# Create the jenkins user
- user: name=jenkins comment="Jenkins user" shell=/bin/bash state=present

# Not using the Ansible module 'authorized_key' as it's not working as documented
- name: Create .ssh folder
  file: path=/home/jenkins/.ssh state=directory mode=0700 owner=jenkins

# Install Maven 3.2.5

- name: Download Maven
  get_url:
    url=http://www.mirrorservice.org/sites/ftp.apache.org/maven/maven-3/3.2.5/binaries/apache-maven-3.2.5-bin.tar.gz
    dest=/home/jenkins/apache-maven-3.2.5-bin.tar.gz
    mode=0640

- name: Install Maven
  unarchive:
    src=/home/jenkins/apache-maven-3.2.5-bin.tar.gz
    dest=/home/jenkins/
    copy=no
    creates=/home/jenkins/apache-maven-3.2.5



Install Maven 3.2.5 on all nodes
Install Maven 3.2.5 on all nodes
