forked from betagouv/datapass
-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy-dev.yml
39 lines (37 loc) · 1.11 KB
/
deploy-dev.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
- hosts: datapass-front
tasks:
- name: deploy front
become: yes
become_user: "{{ app_user }}"
script: ./scripts/deploy-dev.sh signup-front
tags:
- front
- hosts: datapass-back
tasks:
- name: enable altering postgres tables
become: yes
become_user: postgres
command: psql -d signup-back -c 'ALTER TABLE "events" DISABLE TRIGGER ALL;ALTER TABLE "users" DISABLE TRIGGER ALL;ALTER TABLE "enrollments" DISABLE TRIGGER ALL;'
ignore_errors: yes # at first run, these tables may not exist yet
tags:
- back
- name: deploy back
become: yes
become_user: "{{ app_user }}"
script: ./scripts/deploy-dev.sh signup-back
tags:
- back
- name: disable altering postgres tables
become: yes
become_user: postgres
command: psql -d signup-back -c 'ALTER TABLE "events" ENABLE TRIGGER ALL;ALTER TABLE "users" ENABLE TRIGGER ALL;ALTER TABLE "enrollments" ENABLE TRIGGER ALL;'
tags:
- back
- hosts: api-auth
tasks:
- name: deploy api-auth
become: yes
become_user: "{{ app_user }}"
script: ./scripts/deploy-dev.sh api-auth
tags:
- api-auth