aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Daudt <kdaudt@alpinelinux.org>2022-01-02 11:00:47 +0000
committerKevin Daudt <kdaudt@alpinelinux.org>2022-01-02 11:18:07 +0000
commita78463bb51db199426cad58c8f7861d77aebf75e (patch)
treef3beb24372a141cccc66430c0b430100bbea48d0
parent90e851a85bfb0d5201b2ae5ed5e12a0e08721c3e (diff)
downloadaports-a78463bb51db199426cad58c8f7861d77aebf75e.tar.gz
aports-a78463bb51db199426cad58c8f7861d77aebf75e.tar.bz2
aports-a78463bb51db199426cad58c8f7861d77aebf75e.tar.xz
community/zabbix: fix permissions on existing log files
Now that the service runs as zabbix, the service will fail to run if the log files are still owned by root. Fix the permissions when starting the service.
-rw-r--r--community/zabbix/APKBUILD4
-rw-r--r--community/zabbix/zabbix-agent2.initd2
2 files changed, 4 insertions, 2 deletions
diff --git a/community/zabbix/APKBUILD b/community/zabbix/APKBUILD
index 0446e0b2db..741ea8689e 100644
--- a/community/zabbix/APKBUILD
+++ b/community/zabbix/APKBUILD
@@ -4,7 +4,7 @@
# Maintainer: Kevin Daudt <kdaudt@alpinelinux.org>
pkgname=zabbix
pkgver=5.4.9
-pkgrel=1
+pkgrel=2
pkgdesc="Enterprise-class open source distributed monitoring"
url="http://www.zabbix.com"
arch="all"
@@ -262,7 +262,7 @@ sha512sums="
9998ee172a28002d98bacc3f76038ff52b8cf2b206e101418d76b4ca3de94afaf92cb4f7a6235ecf177f74beb9dd3ea1f3983c4f164b4f60bb601acba65aa175 zabbix-server.initd
9c06527bf653c40585fa7eeb3f7a0b2fc454031d24cd0d1633aed87b78a681c5227a193c5b9fcfcea0839135874e27ba7dd9b198573f905f680a2856f79e9512 zabbix-server.confd
7beca0fc6e254c1692e0e74deb9eb3d06ac78f5f6b08f3ab0491861e11e09f00f57bb4d22e11517dab86456e87bd13110805bfb38a715d2f1e68549937b29c76 zabbix-agentd.initd
-83673e526aa063ed866d2dd6f7f60b71e4823e0d5141a258720e0dccbf65a5668f0b1c30e083ad7e94754071d544747d11322712d0e1e45456d871105aaf38d9 zabbix-agent2.initd
+fed1e11ca4d97ad348308d02dff800598748c427bc427c3d52b9bca6a9269904c83ae6be08bacccc65d3d71c6ce50f895782d0650e27244bd2bdbe4ecb807e78 zabbix-agent2.initd
a26e7ac422ff60a4b8eed3603022c3a1bde640870bb9286ab061c3cb5c2fd7e91ddb317cb3d1cf61034adda0a080fc212ad416c9e2853a1deb03c5279753f4e2 zabbix-proxy.initd
9fc413b11a01c8202c7ee1c7950d6ca3de2d2d6cd01bea994cd4bc412533b53c4e4b1f58fc3c8df16ea70902053e278e2c5dcc936ce3e0a686a6eac62310ef53 zabbix-getloadavg.patch
7f70dfd602aa164ec8cc65ebb7e8274c685975f6aea9051933928051b8d9b6e368e5a673a07e7084a2105468c5085d72fa7b9f934460f10648d594f28f031a91 automake.patch
diff --git a/community/zabbix/zabbix-agent2.initd b/community/zabbix/zabbix-agent2.initd
index 1d04fd01e1..e988e8f087 100644
--- a/community/zabbix/zabbix-agent2.initd
+++ b/community/zabbix/zabbix-agent2.initd
@@ -6,5 +6,7 @@ command_user="zabbix:zabbix"
start_pre() {
checkpath --directory --owner zabbix:zabbix /var/log/zabbix
+ # fix log files created as root
+ checkpath --file --owner zabbix:zabbix /var/log/zabbix/zabbix_agent2.log
checkpath --directory --owner zabbix:zabbix /run/zabbix
}