Skip to content
Next Next commit
feat: limit /etc to readonly
https://www.freedesktop.org/software/systemd/man/latest/systemd.exec.html#ReadWritePaths= Prevent postgres, or child-process of, from writing to /etc
  • Loading branch information
staaldraad committed Mar 21, 2025
commit 2d6268fb585e6b6fb9bc5db867c1644cd491651e
3 changes: 3 additions & 0 deletions ansible/files/postgresql_config/postgresql.service.j2
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,8 @@ RestartSec=5
OOMScoreAdjust=-1000
EnvironmentFile=-/etc/environment.d/postgresql.env
LimitNOFILE=16384
{% if supabase_internal is defined %}
ReadOnlyPaths=/etc
{% endif %}
[Install]
WantedBy=multi-user.target