attempt to package
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
7b196bca76
commit
632c48ea54
|
@ -3,3 +3,4 @@ go.mod
|
|||
go.sum
|
||||
|
||||
powerpaneld
|
||||
files/
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
#!/bin/bash -x
|
||||
|
||||
# this is the systemd control file
|
||||
mkdir -p files/lib/systemd/system/
|
||||
cp powerpaneld.service files/lib/systemd/system/
|
2
control
2
control
|
@ -4,6 +4,8 @@ Package: powerpaneld
|
|||
Maintainer: Jeff Carr <jcarr@wit.com>
|
||||
Architecture: amd64
|
||||
Depends: powerpanel
|
||||
URL: https://git.wit.org/jcarr/powerpaneld.git
|
||||
Description: serves cyberpower UPS data on http for uptime checks
|
||||
simply dumps the status of the UPS to port 3000 so uptime checks
|
||||
can monitor utility power grid failures
|
||||
systemctl enable powerpaneld.service
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
[Unit]
|
||||
Description=powerpaneld
|
||||
|
||||
[Service]
|
||||
User=root
|
||||
Type=forking
|
||||
ExecStart=/usr/bin/powerpaneld
|
||||
ExecStop=killall powerpaneld
|
||||
TimeOutSec=30
|
||||
Restart=on-failure
|
||||
RestartSec=30
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in New Issue