Skip to content

Commit

Permalink
Separate schema and data migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
mattwr18 committed Sep 2, 2024
1 parent f1b3961 commit f2c94f7
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions ansible/roles/installation/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,12 @@
community.docker.docker_prune:
images: yes

- name: Create and migrate database
- name: Run schema migrations
command:
cmd: docker compose -f docker-compose.yml -f docker-compose.prod.yml exec app bin/rails db:migrate:with_data
cmd: docker compose -f docker-compose.yml -f docker-compose.prod.yml exec app bin/rails db:migrate
chdir: /home/ansible

- name: Run data migrations
command:
cmd: docker compose -f docker-compose.yml -f docker-compose.prod.yml exec app bin/rails data:migrate
chdir: /home/ansible

0 comments on commit f2c94f7

Please sign in to comment.