aboutsummaryrefslogtreecommitdiff
path: root/utils/ng/systemd
diff options
context:
space:
mode:
authorKunoiSayami <[email protected]>2022-10-25 22:12:18 +0800
committerKunoiSayami <[email protected]>2022-10-25 22:12:18 +0800
commit125ebfac956440f3a26e160a02d0c54c402a7bca (patch)
treeeae012a8cfb277f7f7649d2a9dc6705bb43130e1 /utils/ng/systemd
parentdf89a33152cf430fdc6fca0a70f47e60a5ea1ef7 (diff)
feat(script): Add upload rated scripts
Signed-off-by: KunoiSayami <[email protected]>
Diffstat (limited to 'utils/ng/systemd')
-rw-r--r--utils/ng/systemd/update-repo-notify.service7
-rw-r--r--utils/ng/systemd/update-repo-notify.socket16
2 files changed, 23 insertions, 0 deletions
diff --git a/utils/ng/systemd/update-repo-notify.service b/utils/ng/systemd/update-repo-notify.service
new file mode 100644
index 0000000..e609a8a
--- /dev/null
+++ b/utils/ng/systemd/update-repo-notify.service
@@ -0,0 +1,7 @@
+[Unit]
+Description=Update repo notify service
+
+[Service]
+User=update-database
+DynamicUser=yes
+ExecStart=/var/lib/update/update-db.py /run/update-repo-notify.sock \ No newline at end of file
diff --git a/utils/ng/systemd/update-repo-notify.socket b/utils/ng/systemd/update-repo-notify.socket
new file mode 100644
index 0000000..f14743c
--- /dev/null
+++ b/utils/ng/systemd/update-repo-notify.socket
@@ -0,0 +1,16 @@
+[Unit]
+Description=Update repo notify socket
+
+[Socket]
+# If /var/run is not implemented as a symlink to /run, you may need to
+# specify ListenStream=/var/run/docker.sock instead.
+ListenStream=/run/update-repo-notify.sock
+SocketMode=0660
+SocketUser=update-database
+SocketGroup=http
+#Accept=yes
+MaxConnections=1
+FlushPending=yes
+
+[Install]
+WantedBy=sockets.target \ No newline at end of file