diff options
author | Pavel Raiskup <praiskup@redhat.com> | 2014-09-16 09:18:54 +0200 |
---|---|---|
committer | Pavel Raiskup <praiskup@redhat.com> | 2014-09-16 13:46:43 +0200 |
commit | c9bdc25b4d117b63c7bae4a1400e0ade3cd7a41b (patch) | |
tree | eb03fcf98cb3aae39a4f4b01ab43f9ffc9a46898 /postgresql.service.in | |
parent | 8b9b256fee3c7b59d456e1f7c85489fdddf9f888 (diff) | |
download | postgresql-setup-c9bdc25b4d117b63c7bae4a1400e0ade3cd7a41b.tar.gz postgresql-setup-c9bdc25b4d117b63c7bae4a1400e0ade3cd7a41b.tar.xz postgresql-setup-c9bdc25b4d117b63c7bae4a1400e0ade3cd7a41b.zip |
postgresql-setup: don't expect /etc/postgresql/* exists
That concept was against systemd intentions. From now we
should stop using .include statement in service files and
encourage people using the systemd's drop-in feature. That
complicates things a little, at least until the rhbz#1139148
is not resolved somehow.
Diffstat (limited to 'postgresql.service.in')
-rw-r--r-- | postgresql.service.in | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/postgresql.service.in b/postgresql.service.in index 4b9fc95..ace3ebb 100644 --- a/postgresql.service.in +++ b/postgresql.service.in @@ -1,7 +1,8 @@ # It's not recommended to modify this file in-place, because it will be -# overwritten during package upgrades. If you want to customize, the -# best way is to edit configuration file /etc/postgresql/$SERVICE_NAME -# (where by default, SERVICE_NAME is postgresql). +# overwritten during package upgrades. It is recommended to use systemd +# "dropin" feature; i.e. create file with suffix .conf under +# @userunitsdir@/UNITNAME.service.d directory overriding the +# unit's defaults. Look at systemd.unit(5) manual page for more info. [Unit] Description=PostgreSQL database server @@ -13,8 +14,6 @@ Type=forking User=postgres Group=postgres -EnvironmentFile=-@PKGCONFIG_DIR@/%N - # Where to send early-startup messages from the server (before the logging # options of postgresql.conf take effect) # This is normally controlled by the global default set by systemd @@ -27,6 +26,8 @@ OOMScoreAdjust=-1000 Environment=PG_OOM_ADJUST_FILE=/proc/self/oom_score_adj Environment=PG_OOM_ADJUST_VALUE=0 +Environment=PGDATA=@PGDATADIR@ + ExecStartPre=@libexecdir@/postgresql-check-db-dir %N # Temporarily use postgresql-ctl wrapper around pg_ctl until there will |