summaryrefslogtreecommitdiffstats
path: root/network/opendkim/opendkim.SlackBuild
diff options
context:
space:
mode:
author Robby Workman <rworkman@slackbuilds.org>2021-07-18 21:22:57 -0500
committer Willy Sudiarto Raharjo <willysr@slackbuilds.org>2021-07-19 16:23:33 +0700
commit3de874d2564d49bf95012400a0cdf402237b4710 (patch)
tree97e208e04e5ed5e8aa11d8608698c451a2a30608 /network/opendkim/opendkim.SlackBuild
parent8679fda5afda338255385a3ed9ab6950943e1d50 (diff)
downloadslackbuilds-3de874d2564d49bf95012400a0cdf402237b4710.tar.gz
slackbuilds-3de874d2564d49bf95012400a0cdf402237b4710.tar.xz
network/opendkim: Fixed piddir creation at init
This commit also stops using $USER within the build script; this should not be set during scripts. Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'network/opendkim/opendkim.SlackBuild')
-rw-r--r--network/opendkim/opendkim.SlackBuild7
1 files changed, 4 insertions, 3 deletions
diff --git a/network/opendkim/opendkim.SlackBuild b/network/opendkim/opendkim.SlackBuild
index 3661a69da9..04625cc3de 100644
--- a/network/opendkim/opendkim.SlackBuild
+++ b/network/opendkim/opendkim.SlackBuild
@@ -143,10 +143,11 @@ mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a FEATURES INSTALL KNOWNBUGS LICENSE* README* RELEASE_NOTES* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
-mkdir -p $PKG/var/run/opendkim
-chown $USER:$GROUP $PKG/var/run/opendkim/
+mkdir -p $PKG/etc/rc.d
install -m 0640 -D $PRGNAM/opendkim.conf.simple $PKG/etc/opendkim.conf.new
-install -m 0755 -D $CWD/rc.opendkim $PKG/etc/rc.d/rc.opendkim.new
+sed -e "s,@DKUSER@,$DKUSER,g" -e "s,@DKGROUP@,$DKGROUP,g" \
+ $CWD/rc.opendkim > $PKG/etc/rc.d/rc.opendkim.new
+chmod 0755 $PKG/etc/rc.d/rc.opendkim.new
# Change KeyFile to match rc.opendkim
sed -i 's|^KeyFile.*|KeyFile /etc/opendkim/keys/default.private|' $PKG/etc/opendkim.conf.new