From 6d397ba9d94c18e9d7939f87fbac47ad116c6e5f Mon Sep 17 00:00:00 2001 From: Cameron Hyde Date: Fri, 4 Oct 2024 08:28:18 +1000 Subject: [PATCH] Dev Ansible deploy - run update tags only --- .github/workflows/ansible-deploy-dev.yml | 2 +- ansible/roles/galaxy_labs_engine/tasks/main.yml | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ansible-deploy-dev.yml b/.github/workflows/ansible-deploy-dev.yml index bf22cb5..6ad372a 100644 --- a/.github/workflows/ansible-deploy-dev.yml +++ b/.github/workflows/ansible-deploy-dev.yml @@ -40,7 +40,7 @@ jobs: - name: Run Ansible Playbook run: | cd ansible - ansible-playbook -i hosts dev.yml + ansible-playbook -i hosts dev.yml --tags update env: ANSIBLE_HOST_KEY_CHECKING: 'False' ANSIBLE_REMOTE_USER: ${{ secrets.SSH_USER }} diff --git a/ansible/roles/galaxy_labs_engine/tasks/main.yml b/ansible/roles/galaxy_labs_engine/tasks/main.yml index c5ac8ba..74b7476 100644 --- a/ansible/roles/galaxy_labs_engine/tasks/main.yml +++ b/ansible/roles/galaxy_labs_engine/tasks/main.yml @@ -51,26 +51,25 @@ loop: "{{ labs_engine.files }}" tags: config -- name: update media file ownership +- name: Set media file ownership file: dest={{ django_root }}/app/media owner=www-data group=www-data mode=u=rwX,g=rwX,o=rwX recurse=yes tags: - permissions - update -- name: update log file ownership +- name: Set log file ownership file: dest={{ django_root }}/app/logs owner=www-data group=www-data mode=u=rwX,g=rwX,o=rwX recurse=yes tags: - permissions - update -- name: update sqlite3 database ownership +- name: Update sqlite3 database ownership file: dest={{ django_root }}/db.sqlite3 owner=www-data group=www-data mode=u=rw,g=rw,o=r tags: - permissions - - update ignore_errors: yes -- name: update sqlite3 database directory permissions +- name: Update sqlite3 database directory permissions file: dest: "{{ django_root }}" owner: root @@ -78,7 +77,6 @@ mode: u=rwx,g=rwx,o=rx tags: - permissions - - update - name: Django create django_cache table with 'manage.py createcachetable' shell: >