Skip to content

Commit 08b6fb2

Browse files
committed
feat: WIP switch off 2nd phase items
1 parent 236fe71 commit 08b6fb2

File tree

2 files changed

+65
-61
lines changed

2 files changed

+65
-61
lines changed

ansible/playbook.yml

Lines changed: 63 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -71,42 +71,45 @@
7171
tags:
7272
- install-supabase-internal
7373

74-
- name: Start Postgres Database
75-
systemd:
76-
name: postgresql
77-
state: started
78-
when: not ebssurrogate_mode
79-
80-
- name: Start Postgres Database without Systemd
81-
become: yes
82-
become_user: postgres
83-
shell:
84-
cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data start
85-
when: ebssurrogate_mode
74+
# - name: Start Postgres Database
75+
# systemd:
76+
# name: postgresql
77+
# state: started
78+
# when: not ebssurrogate_mode
79+
80+
# - name: Start Postgres Database without Systemd
81+
# become: yes
82+
# become_user: postgres
83+
# shell:
84+
# cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data start
85+
# when: ebssurrogate_mode
86+
# TODO bring into 2nd phase
8687

8788
- name: Adjust APT update intervals
8889
copy:
8990
src: files/apt_periodic
9091
dest: /etc/apt/apt.conf.d/10periodic
9192

92-
- name: Transfer init SQL files
93-
copy:
94-
src: files/{{ item.source }}
95-
dest: /tmp/{{ item.dest }}
96-
loop: "{{ sql_files }}"
93+
# - name: Transfer init SQL files
94+
# copy:
95+
# src: files/{{ item.source }}
96+
# dest: /tmp/{{ item.dest }}
97+
# loop: "{{ sql_files }}"
9798

98-
- name: Execute init SQL files
99-
become: yes
100-
become_user: postgres
101-
shell:
102-
cmd: /usr/lib/postgresql/bin/psql -f /tmp/{{ item.dest }}
103-
loop: "{{ sql_files }}"
99+
# - name: Execute init SQL files
100+
# become: yes
101+
# become_user: postgres
102+
# shell:
103+
# cmd: /usr/lib/postgresql/bin/psql -f /tmp/{{ item.dest }}
104+
# loop: "{{ sql_files }}"
105+
106+
# - name: Delete SQL scripts
107+
# file:
108+
# path: /tmp/{{ item.dest }}
109+
# state: absent
110+
# loop: "{{ sql_files }}"
111+
# TODO bring into 2nd phase
104112

105-
- name: Delete SQL scripts
106-
file:
107-
path: /tmp/{{ item.dest }}
108-
state: absent
109-
loop: "{{ sql_files }}"
110113

111114
- name: First boot optimizations
112115
import_tasks: tasks/internal/optimizations.yml
@@ -140,34 +143,35 @@
140143
update_cache: yes
141144
cache_valid_time: 3600
142145

143-
- name: Clean out build dependencies
144-
import_tasks: tasks/clean-build-dependencies.yml
145-
146-
- name: Restart Postgres Database without Systemd
147-
become: yes
148-
become_user: postgres
149-
shell:
150-
cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data restart -o "-c shared_preload_libraries='pg_tle'"
151-
when: ebssurrogate_mode
152-
153-
- name: Run migrations
154-
import_tasks: tasks/setup-migrations.yml
155-
tags:
156-
- migrations
157-
158-
- name: Stop Postgres Database without Systemd
159-
become: yes
160-
become_user: postgres
161-
shell:
162-
cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data stop
163-
when: ebssurrogate_mode
164-
165-
- name: Run unit tests
166-
import_tasks: tasks/test-image.yml
167-
tags:
168-
- unit-tests
169-
170-
- name: Collect Postgres binaries
171-
import_tasks: tasks/internal/collect-pg-binaries.yml
172-
tags:
173-
- collect-binaries
146+
# - name: Clean out build dependencies
147+
# import_tasks: tasks/clean-build-dependencies.yml
148+
149+
# - name: Restart Postgres Database without Systemd
150+
# become: yes
151+
# become_user: postgres
152+
# shell:
153+
# cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data restart -o "-c shared_preload_libraries='pg_tle'"
154+
# when: ebssurrogate_mode
155+
156+
# - name: Run migrations
157+
# import_tasks: tasks/setup-migrations.yml
158+
# tags:
159+
# - migrations
160+
161+
# - name: Stop Postgres Database without Systemd
162+
# become: yes
163+
# become_user: postgres
164+
# shell:
165+
# cmd: /usr/lib/postgresql/bin/pg_ctl -D /var/lib/postgresql/data stop
166+
# when: ebssurrogate_mode
167+
168+
# - name: Run unit tests
169+
# import_tasks: tasks/test-image.yml
170+
# tags:
171+
# - unit-tests
172+
173+
# - name: Collect Postgres binaries
174+
# import_tasks: tasks/internal/collect-pg-binaries.yml
175+
# tags:
176+
# - collect-binaries
177+
#TODO bring into 2nd phase

ansible/tasks/setup-pgbouncer.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# PgBouncer
2-
- name: create postgres group
2+
- name: create ssl-cert group
33
group:
4-
name: postgres
4+
name: ssl-cert
55
state: present
66

77
- name: PgBouncer - download & install dependencies

0 commit comments

Comments
 (0)