diff options
author | Elias Probst <mail@eliasprobst.eu> | 2015-10-23 23:25:09 +0200 |
---|---|---|
committer | Elias Probst <mail@eliasprobst.eu> | 2015-10-25 20:45:00 +0100 |
commit | 4d732339911b0ea2aa9b994efe17a92d42281504 (patch) | |
tree | 423f1e500ba025d9f664f3206a6b392d40e654fb /dev-db/postgresql | |
parent | 5d71738e378482c238ea5660c5961b3aa3a740dc (diff) | |
download | gentoo-4d732339911b0ea2aa9b994efe17a92d42281504.tar.gz gentoo-4d732339911b0ea2aa9b994efe17a92d42281504.tar.xz |
dev-db/postgresql: Handle RuntimeDirectory in systemd unit
Instead of using a separate `tmpfiles.d` definition to create
`/run/postgresql`, let the service unit take care of it on its
own. This prevents situations where the postgresql service can't
start because `systemd-tmpfiles` wasn't run yet.
Bug: https://bugs.gentoo.org/show_bug.cgi?id=563122
Package-Manager: portage-2.2.23
Diffstat (limited to 'dev-db/postgresql')
-rw-r--r-- | dev-db/postgresql/files/postgresql.service | 4 | ||||
-rw-r--r-- | dev-db/postgresql/files/postgresql.tmpfilesd | 1 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.0.23-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.0.23.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.1.19-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.1.19.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.2.14-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.2.14.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.3.10-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.3.10.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.4.5-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.4.5.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9.5_beta1-r1.ebuild (renamed from dev-db/postgresql/postgresql-9.5_beta1.ebuild) | 2 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-9999.ebuild | 2 |
9 files changed, 4 insertions, 15 deletions
diff --git a/dev-db/postgresql/files/postgresql.service b/dev-db/postgresql/files/postgresql.service index 20ed27a10f2..a607169d22f 100644 --- a/dev-db/postgresql/files/postgresql.service +++ b/dev-db/postgresql/files/postgresql.service @@ -47,5 +47,9 @@ TimeoutSec=300 # Disable OOM kill on the postmaster OOMScoreAdjust=-1000 +# Make sure the required runtimedir is present +RuntimeDirectory=postgresql +RuntimeDirectoryMode=1775 + [Install] WantedBy=multi-user.target diff --git a/dev-db/postgresql/files/postgresql.tmpfilesd b/dev-db/postgresql/files/postgresql.tmpfilesd deleted file mode 100644 index 26f44efa328..00000000000 --- a/dev-db/postgresql/files/postgresql.tmpfilesd +++ /dev/null @@ -1 +0,0 @@ -d /run/postgresql 1775 postgres postgres - diff --git a/dev-db/postgresql/postgresql-9.0.23.ebuild b/dev-db/postgresql/postgresql-9.0.23-r1.ebuild index 174a686213e..ac1b4fe859a 100644 --- a/dev-db/postgresql/postgresql-9.0.23.ebuild +++ b/dev-db/postgresql/postgresql-9.0.23-r1.ebuild @@ -198,8 +198,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9.1.19.ebuild b/dev-db/postgresql/postgresql-9.1.19-r1.ebuild index e2ab37ede1c..817622c4a53 100644 --- a/dev-db/postgresql/postgresql-9.1.19.ebuild +++ b/dev-db/postgresql/postgresql-9.1.19-r1.ebuild @@ -202,8 +202,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9.2.14.ebuild b/dev-db/postgresql/postgresql-9.2.14-r1.ebuild index 6ec39d36a74..83a2fa7543c 100644 --- a/dev-db/postgresql/postgresql-9.2.14.ebuild +++ b/dev-db/postgresql/postgresql-9.2.14-r1.ebuild @@ -196,8 +196,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9.3.10.ebuild b/dev-db/postgresql/postgresql-9.3.10-r1.ebuild index dc084ca55d1..2367c975064 100644 --- a/dev-db/postgresql/postgresql-9.3.10.ebuild +++ b/dev-db/postgresql/postgresql-9.3.10-r1.ebuild @@ -196,8 +196,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9.4.5.ebuild b/dev-db/postgresql/postgresql-9.4.5-r1.ebuild index a411b383766..d705b100381 100644 --- a/dev-db/postgresql/postgresql-9.4.5.ebuild +++ b/dev-db/postgresql/postgresql-9.4.5-r1.ebuild @@ -228,8 +228,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9.5_beta1.ebuild b/dev-db/postgresql/postgresql-9.5_beta1-r1.ebuild index 50d2cecefa6..cc14882a351 100644 --- a/dev-db/postgresql/postgresql-9.5_beta1.ebuild +++ b/dev-db/postgresql/postgresql-9.5_beta1-r1.ebuild @@ -234,8 +234,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session diff --git a/dev-db/postgresql/postgresql-9999.ebuild b/dev-db/postgresql/postgresql-9999.ebuild index 36e35fdb8ba..c2fe866097b 100644 --- a/dev-db/postgresql/postgresql-9999.ebuild +++ b/dev-db/postgresql/postgresql-9999.ebuild @@ -186,8 +186,6 @@ src_install() { "${FILESDIR}/${PN}.service" | \ systemd_newunit - ${PN}-${SLOT}.service - systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf - newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session |