Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: release updates to run physical backup as a service to 15.6 image #1248

Merged
merged 2 commits into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ansible/files/adminapi.sudoers.conf
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ Cmnd_Alias PGBOUNCER = /bin/systemctl start pgbouncer.service, /bin/systemctl st
%adminapi ALL= NOPASSWD: /usr/bin/systemctl restart postgresql.service
%adminapi ALL= NOPASSWD: /usr/bin/systemctl show -p NRestarts postgresql.service
%adminapi ALL= NOPASSWD: /usr/bin/systemctl restart adminapi.service
%adminapi ALL= NOPASSWD: /usr/bin/systemctl is-active commence-backup.service
%adminapi ALL= NOPASSWD: /usr/bin/systemctl start commence-backup.service
%adminapi ALL= NOPASSWD: /bin/systemctl daemon-reload
%adminapi ALL= NOPASSWD: /bin/systemctl restart services.slice
%adminapi ALL= NOPASSWD: /usr/sbin/nft -f /etc/nftables/supabase_managed.conf
Expand Down
12 changes: 12 additions & 0 deletions ansible/files/commence-backup.service.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[Unit]
Description=Async commence physical backup

[Service]
Type=simple
User=adminapi
ExecStart=/usr/bin/admin-mgr commence-backup --run-as-service true
Restart=no
OOMScoreAdjust=-1000

[Install]
WantedBy=multi-user.target
5 changes: 5 additions & 0 deletions ansible/tasks/internal/admin-api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,11 @@
src: files/adminapi.service.j2
dest: /etc/systemd/system/adminapi.service

- name: adminapi - create service file for commence backup process
template:
src: files/commence-backup.service.j2
dest: /etc/systemd/system/commence-backup.service

- name: UFW - Allow connections to adminapi ports
ufw:
rule: allow
Expand Down
4 changes: 2 additions & 2 deletions ansible/vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ postgres_exporter_release_checksum:
arm64: sha256:29ba62d538b92d39952afe12ee2e1f4401250d678ff4b354ff2752f4321c87a0
amd64: sha256:cb89fc5bf4485fb554e0d640d9684fae143a4b2d5fa443009bd29c59f9129e84

adminapi_release: 0.68.0
adminmgr_release: 0.22.1
adminapi_release: 0.71.1
adminmgr_release: 0.24.0

# Postgres Extensions
postgis_release: "3.3.2"
Expand Down
2 changes: 1 addition & 1 deletion common-nix.vars.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1 +1 @@
postgres-version = "15.6.1.125"
postgres-version = "15.6.1.126"
Loading