summaryrefslogtreecommitdiff
path: root/src/systemd/vyos-http-api.service
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@baturin.org>2019-09-04 15:39:38 +0200
committerDaniil Baturin <daniil@baturin.org>2019-09-04 15:39:38 +0200
commit4d50edfc9543f3d27eb83300dd27d598ffe63fe2 (patch)
tree6d403977484aa5231659d17efdd031ea01c1a768 /src/systemd/vyos-http-api.service
parent6167fab1737ef59f223ee6c7fff0a493c76d9793 (diff)
downloadvyos-1x-4d50edfc9543f3d27eb83300dd27d598ffe63fe2.tar.gz
vyos-1x-4d50edfc9543f3d27eb83300dd27d598ffe63fe2.zip
T1443: backport the HTTP API to crux.
Implementation by Daniil Baturin and John Estabrook.
Diffstat (limited to 'src/systemd/vyos-http-api.service')
-rw-r--r--src/systemd/vyos-http-api.service24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/systemd/vyos-http-api.service b/src/systemd/vyos-http-api.service
new file mode 100644
index 000000000..4fa68b4ff
--- /dev/null
+++ b/src/systemd/vyos-http-api.service
@@ -0,0 +1,24 @@
+[Unit]
+Description=VyOS HTTP API service
+After=auditd.service systemd-user-sessions.service time-sync.target vyos-router.service
+Requires=vyos-router.service
+
+[Service]
+ExecStartPre=/usr/libexec/vyos/init/vyos-config
+ExecStart=/usr/bin/python3 -u /usr/libexec/vyos/services/vyos-http-api-server
+Type=idle
+KillMode=process
+
+SyslogIdentifier=vyos-http-api
+SyslogFacility=daemon
+
+Restart=on-failure
+
+# Does't work but leave it here
+User=root
+Group=vyattacfg
+
+[Install]
+# Installing in a earlier target leaves ExecStartPre waiting
+WantedBy=getty.target
+