diff options
Diffstat (limited to 'baserock_webserver/image-config.yml')
-rw-r--r-- | baserock_webserver/image-config.yml | 45 |
1 files changed, 24 insertions, 21 deletions
diff --git a/baserock_webserver/image-config.yml b/baserock_webserver/image-config.yml index 29c1ba5f..9ce3e9bf 100644 --- a/baserock_webserver/image-config.yml +++ b/baserock_webserver/image-config.yml @@ -3,33 +3,36 @@ # This expects to be run on a Fedora 26 cloud image. --- - hosts: webserver - gather_facts: false become: yes become_method: sudo tasks: - # see: https://fedoramagazine.org/getting-ansible-working-fedora-23/ - - name: install python2 and required deps for ansible modules - raw: dnf install -y python2 python2-dnf libselinux-python - - - name: enable persistant journal - shell: mkdir /var/log/journal - args: - creates: /var/log/journal - name: ensure system up to date - dnf: name=* state=latest - - - name: Cherokee webserver package - dnf: name=cherokee state=latest + apt: + upgrade: yes + update_cache: yes - - name: Cherokee configuration - copy: src=etc/cherokee/cherokee.conf dest=/etc/cherokee/ + - name: Install nginx package + apt: + pkg: + - nginx + - libnginx-mod-http-fancyindex + - python3-pip + - python2-minimal + update_cache: yes - - name: install lvm2 tools - dnf: name=lvm2 state=latest + - name: Download get-pip.py + get_url: + url: https://bootstrap.pypa.io/pip/2.7/get-pip.py + dest: /opt/get-pip.py + become: yes - - name: disable SELinux on subsequent boots - selinux: state=disabled + - name: Install pip2 + command: python2 /opt/get-pip.py + args: + creates: /usr/local/bin/pip2 + become: yes - - name: disable SELinux on current boot - command: setenforce 0 + - name: install lvm2 tools + apt: + name: lvm2 |