summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustin Gottula2021-07-08 16:28:31 -0700
committerJustin Gottula2021-07-08 16:28:31 -0700
commitf87632201cb5142bf6e1b15f0800db382c63175b (patch)
treeec6e3ec2d405c63319aa14254600ff5fd8ddb12e
parente13522b9081e3edc9bce4cd692b3219cb6e66386 (diff)
downloadaur-f87632201cb5142bf6e1b15f0800db382c63175b.tar.gz
Ease modification of wsdd parameters by using systemd environment file
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD9
-rw-r--r--wsdd.conf4
-rw-r--r--wsdd.service4
4 files changed, 18 insertions, 5 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ee254270321..a56a5b6254f 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -6,10 +6,12 @@ pkgbase = wsdd
arch = any
license = MIT
depends = samba
+ backup = etc/conf.d/wsdd
source = wsdd-0.6.4.tar.gz::https://github.com/christgau/wsdd/archive/v0.6.4.tar.gz
source = wsdd.service
+ source = wsdd.conf
sha256sums = bb8bc6411b70be68369c53bf75827ac77f16a5bf5606de6536dd7e6d6ce4c2be
- sha256sums = 5408872bb509fc130de00099407c7eef6c68b7913b54649970e8e3a2f54f4316
+ sha256sums = 8f4326841b5ba899752ba30554fcc5ea4b2353dadb951535fd62e234fb1f5009
+ sha256sums = 7330cfb5cabbc7f3116781baa0f92c8bb4ac86a20f22edef5c5d98997f253c08
pkgname = wsdd
-
diff --git a/PKGBUILD b/PKGBUILD
index 457fefc1990..ecb84839180 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -11,13 +11,18 @@ license=('MIT')
depends=('samba')
+backup=('etc/conf.d/wsdd')
+
source=("wsdd-${pkgver}.tar.gz::https://github.com/christgau/wsdd/archive/v${pkgver}.tar.gz"
- 'wsdd.service')
+ 'wsdd.service'
+ 'wsdd.conf')
sha256sums=('bb8bc6411b70be68369c53bf75827ac77f16a5bf5606de6536dd7e6d6ce4c2be'
- '5408872bb509fc130de00099407c7eef6c68b7913b54649970e8e3a2f54f4316')
+ '8f4326841b5ba899752ba30554fcc5ea4b2353dadb951535fd62e234fb1f5009'
+ '7330cfb5cabbc7f3116781baa0f92c8bb4ac86a20f22edef5c5d98997f253c08')
package() {
install -D -m 755 "${srcdir}/${pkgname}-${pkgver}/src/wsdd.py" "${pkgdir}/usr/bin/wsdd"
+ install -D -m 644 "${srcdir}/wsdd.conf" "${pkgdir}/etc/conf.d/wsdd"
install -D -m 644 "${srcdir}/wsdd.service" "${pkgdir}/usr/lib/systemd/system/wsdd.service"
}
diff --git a/wsdd.conf b/wsdd.conf
new file mode 100644
index 00000000000..2b9534e01d6
--- /dev/null
+++ b/wsdd.conf
@@ -0,0 +1,4 @@
+# command-line parameters for wsdd:
+# modify this file to set workgroup or change other arguments as desired
+# run 'wsdd --help' for a complete list of possible parameters
+PARAMS="--shortlog --workgroup WORKGROUP"
diff --git a/wsdd.service b/wsdd.service
index 3444a3570e1..5a557606a89 100644
--- a/wsdd.service
+++ b/wsdd.service
@@ -9,7 +9,9 @@ Wants=network-online.target
[Service]
DynamicUser=yes
Type=simple
-ExecStart=/usr/bin/wsdd --shortlog --workgroup WORKGROUP
+; Daemon parameters (including e.g. workgroup) are now set via config file:
+EnvironmentFile=/etc/conf.d/wsdd
+ExecStart=/usr/bin/wsdd $PARAMS
[Install]
WantedBy=multi-user.target