fmartingr
/
shelfzilla
Archived
1
0
Fork 0
This repository has been archived on 2021-06-29. You can view files and clone it, but cannot push or open issues or pull requests.
shelfzilla/provisioning/roles/shelfzilla/tasks/post_python.yml

21 lines
813 B
YAML

- name: Pip Install Shelfzilla Deps
pip: requirements="{{shelfzilla_base_path}}/config/production/requirements.txt"
executable="/usr/bin/pip2"
sudo: yes
- lineinfile: dest="{{shelfzilla_base_path}}/shelfzilla/settings/configfile.py"
regexp="^(.*)os\.environ\[\'APP\_CONFIGFILE\'\](.*)$"
state=present
line="\'\1{{ shelfzillla_config_file }}\2\'"
backrefs=yes
sudo: yes
- name: Python Migrate
shell: /usr/bin/python2.7 {{shelfzilla_base_path}}/manage.py migrate --no-initial-data --settings=shelfzilla.settings.configfile
sudo: yes
sudo_user: postgres
- name: Python Collectstatic
shell: /usr/bin/python2.7 {{shelfzilla_base_path}}/manage.py collectstatic --clear --noinput --settings=shelfzilla.settings.configfile
sudo: yes