Move rookeries installation into deployment stand-alone playbook.
This commit is contained in:
parent
950bd84b87
commit
5c8402c98e
|
@ -1,3 +1,30 @@
|
|||
---
|
||||
- include: deployment/rookeries_install.yaml
|
||||
- include: deployment/email_server.yaml
|
||||
- hosts: all
|
||||
sudo: yes
|
||||
vars:
|
||||
web_server_home: /srv/www
|
||||
web_server_group: www-data
|
||||
rookeries_venv: "{{ web_server_home }}/virtualenvs/rookeries"
|
||||
rookeries_package: rookeries-0.4.0.tar.bz2
|
||||
tasks:
|
||||
|
||||
- name: upload + extract rookeries package to web server home
|
||||
unarchive: src=../../../{{ rookeries_package }} dest={{ web_server_home }}/
|
||||
|
||||
- name: install rookeries dependencies
|
||||
pip: requirements=rookeries_webapp/requirements.txt virtualenv={{ rookeries_venv }} chdir={{ web_server_home }}
|
||||
|
||||
- name: install extra MySQL python connector dependency
|
||||
pip: name=mysql-connector-python virtualenv={{ rookeries_venv }} version=1.1.6
|
||||
extra_args='--allow-external mysql-connector-python --allow-unverified mysql-connector-python'
|
||||
|
||||
- name: fix permissions on extracted web app
|
||||
file: path={{ web_server_home }}/rookeries_webapp owner={{ web_server_group }} group={{ web_server_group }}
|
||||
state=directory recurse=yes
|
||||
|
||||
# TODO Step 4 - Setup environment variables on target system related to config.
|
||||
|
||||
- name: install bower dependencies in app
|
||||
command: bower install --allow-root --quiet chdir={{ web_server_home }}/rookeries_webapp
|
||||
# TODO Replace with bower command in future version of Ansible (1.9.0)
|
||||
# bower: path={{ web_server_home }}/rookeries_webapp state=present
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
---
|
||||
- hosts: all
|
||||
sudo: yes
|
||||
vars:
|
||||
web_server_home: /srv/www
|
||||
web_server_group: www-data
|
||||
rookeries_venv: "{{ web_server_home }}/virtualenvs/rookeries"
|
||||
rookeries_package: rookeries-0.4.0.tar.bz2
|
||||
tasks:
|
||||
|
||||
- name: upload + extract rookeries package to web server home
|
||||
unarchive: src=../../../{{ rookeries_package }} dest={{ web_server_home }}/
|
||||
|
||||
- name: install rookeries dependencies
|
||||
pip: requirements=rookeries_webapp/requirements.txt virtualenv={{ rookeries_venv }} chdir={{ web_server_home }}
|
||||
|
||||
- name: install extra MySQL python connector dependency
|
||||
pip: name=mysql-connector-python virtualenv={{ rookeries_venv }} version=1.1.6
|
||||
extra_args='--allow-external mysql-connector-python --allow-unverified mysql-connector-python'
|
||||
|
||||
- name: fix permissions on extracted web app
|
||||
file: path={{ web_server_home }}/rookeries_webapp owner={{ web_server_group }} group={{ web_server_group }}
|
||||
state=directory recurse=yes
|
||||
|
||||
# TODO Step 4 - Setup environment variables on target system related to config.
|
||||
|
||||
- name: install bower dependencies in app
|
||||
command: bower install --allow-root --quiet chdir={{ web_server_home }}/rookeries_webapp
|
||||
# TODO Replace with bower command in future version of Ansible (1.9.0)
|
||||
# bower: path={{ web_server_home }}/rookeries_webapp state=present
|
Loading…
Reference in New Issue