Skip to content

Commit

Permalink
CI Localenv -> Only run backend playbook when repo changed.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbfm committed Jan 30, 2025
1 parent 240dd18 commit efc82a5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .ci/deploy/localenv/ansible/playbook-backend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,17 @@
dest: "{{ repo_dir }}"
version: "development"
force: true # Avoid "would clobber existing tag" error for canary-tag
register: repo_checkout

- name: Provision secrets
ansible.builtin.command:
cmd: "docker compose --file .ci/deploy/localenv/docker-compose.yml up --build provision-secrets"
chdir: "{{ repo_dir }}"
creates: "{{ repo_dir }}/.ci/deploy/localenv/data/secrets/.env"
when: repo_checkout.changed

- name: Start containers
ansible.builtin.command:
cmd: "docker compose --file .ci/deploy/localenv/docker-compose.yml --env-file .ci/deploy/localenv/data/secrets/.env up --detach --build"
chdir: "{{ repo_dir }}"
when: repo_checkout.changed

0 comments on commit efc82a5

Please sign in to comment.