Skip to content

Commit 10a2a17

Browse files
committed
chore: add systemd service
Signed-off-by: AtomicFS <[email protected]>
1 parent 0ff93ff commit 10a2a17

File tree

3 files changed

+20
-6
lines changed

3 files changed

+20
-6
lines changed

.goreleaser.yaml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -149,12 +149,10 @@ nfpms:
149149
bindir: /usr/bin
150150
section: default
151151
priority: extra
152-
#contents:
153-
# # systemd services
154-
# - src: ./scripts/remotelab-server.service
155-
# dst: /usr/lib/systemd/system/remotelab-server.service
156-
# - src: ./scripts/remotelab-set-pins-on-boot.service
157-
# dst: /usr/lib/systemd/system/remotelab-set-pins-on-boot.service
152+
contents:
153+
# systemd services
154+
- src: ./scripts/dutagent.service
155+
dst: /usr/lib/systemd/system/dutagent.service
158156

159157
rpm:
160158
packager: "Jens Drenhaus <[email protected]>"

Taskfile.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ includes:
99
vars:
1010
FWCI_PROJECT_NAME: "test-dutctl"
1111
DUTCTL_CONFIG_FILE: "/etc/dutctl.yaml"
12+
SYSTEMD_FILE: "dutagent.service"

scripts/dutagent.service

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[Unit]
2+
Description=dutagent to run on devices under test
3+
Documentation=https://github.com/BlindspotSoftware/dutctl
4+
Wants=network-online.target
5+
After=network-online.target
6+
7+
[Service]
8+
Environment=EM100_HOME=/root/.em100
9+
# TODO: I think that the 'Environment' needs to be changed or removed
10+
Restart=always
11+
RestartSec=3s
12+
ExecStart=/usr/bin/dutagent -c /etc/dutctl.yaml
13+
14+
[Install]
15+
WantedBy=multi-user.target

0 commit comments

Comments
 (0)