public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/sagan/
Date: Mon, 15 Mar 2021 01:26:02 +0000 (UTC)	[thread overview]
Message-ID: <1615771533.0a0d469ed446b082600e3f4c7db0472dccd87d58.sam@gentoo> (raw)

commit:     0a0d469ed446b082600e3f4c7db0472dccd87d58
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Mar 15 01:25:33 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Mar 15 01:25:33 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0a0d469e

app-admin/sagan: add warning to fix permissions for older installs

Bug: https://bugs.gentoo.org/775902
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-admin/sagan/sagan-2.0.1-r4.ebuild | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/app-admin/sagan/sagan-2.0.1-r4.ebuild b/app-admin/sagan/sagan-2.0.1-r4.ebuild
index 50e4eef4484..aa3ce608b68 100644
--- a/app-admin/sagan/sagan-2.0.1-r4.ebuild
+++ b/app-admin/sagan/sagan-2.0.1-r4.ebuild
@@ -102,9 +102,27 @@ src_install() {
 	dodoc -r extra/*
 }
 
+pkg_preinst() {
+	# bug #775902 revealed that we need 750 on /var/log/sagan or e.g.
+	# logrotate will fail. Let's inform the user to fix up permissions
+	# in such a case.
+	#  (fperms won't modify the live filesystem.)
+	HAD_BROKEN_PERMS=0
+
+	if has_version "<app-admin/sagan-2.0.1-r4" ; then
+		HAD_BROKEN_PERMS=1
+	fi
+}
+
 pkg_postinst() {
 	tmpfiles_process sagan.conf
 
+	if [[ "${HAD_BROKEN_PERMS}" -eq 1 ]] ; then
+		ewarn "Please fix the permissions on ${EPREFIX}/var/log/sagan:"
+		ewarn "e.g. chmod 750 /var/log/sagan"
+		ewarn "See bug #775902"
+	fi
+
 	if use smtp; then
 		ewarn "You have enabled smtp use flag. If you plan on using Sagan with"
 		ewarn "email, create valid writable home directory for user 'sagan'"


             reply	other threads:[~2021-03-15  1:26 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-15  1:26 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-03-08 19:19 [gentoo-commits] repo/gentoo:master commit in: app-admin/sagan/ Arthur Zamarin
2024-11-23 18:27 Michał Górny
2024-11-23 14:32 Michał Górny
2023-06-11  8:22 Joonas Niilola
2022-03-23  1:24 Sam James
2021-07-20 20:30 Conrad Kostecki
2021-07-20 20:30 Conrad Kostecki
2021-07-20 20:22 Conrad Kostecki
2021-07-20 19:36 Conrad Kostecki
2021-07-20 19:36 Conrad Kostecki
2021-03-15  1:26 Sam James
2021-03-15  1:26 Sam James
2021-03-12 15:35 Sam James
2021-03-12 15:28 Sam James
2021-03-12 15:25 Sam James
2021-03-11 12:40 Sam James
2021-03-11 12:39 Sam James
2021-03-11  8:27 Sam James
2021-03-11  8:16 Sam James
2021-03-11  8:07 Sam James
2021-03-11  8:04 Sam James
2021-03-11  7:29 Sam James
2021-02-11  2:12 Sam James
2021-01-06 19:21 Andreas K. Hüttel
2020-09-24  1:06 Aaron Bauman
2017-12-19 21:45 Thomas Deutschmann
2016-05-29 20:21 Alexander Vershilov
2016-04-04  9:00 Ian Delaney
2015-11-01 13:05 Mikle Kolyada
2015-10-30  9:18 Agostino Sarubbo
2015-10-14  9:31 Ian Delaney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1615771533.0a0d469ed446b082600e3f4c7db0472dccd87d58.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox