Rename templates
This commit is contained in:
parent
872a3e782c
commit
1e78f80de7
5
Makefile
5
Makefile
|
|
@ -279,7 +279,8 @@ package_build_linux: readme man linux
|
|||
cp examples/$(CONFIG_FILE).example $@/etc/$(BINARY)/$(CONFIG_FILE)
|
||||
cp LICENSE *.html examples/*?.?* $@/usr/share/doc/$(BINARY)/
|
||||
# These go to their own folder so the img src in the html pages continue to work.
|
||||
cp init/systemd/$(BINARY).service $@/lib/systemd/system/
|
||||
sed -e "s/{{BINARY}}/$(BINARY)/g" -e "s/{{DESC}}/$(DESC)/g" \
|
||||
init/systemd/template.unit.service > $@/lib/systemd/system/$(BINARY).service
|
||||
|
||||
package_build_linux_386: package_build_linux linux386
|
||||
mkdir -p $@
|
||||
|
|
@ -316,7 +317,7 @@ $(BINARY).rb: v$(VERSION).tar.gz.sha256
|
|||
-e "s%{{GHREPO}}%$(GHREPO)%g" \
|
||||
-e "s%{{CONFIG_FILE}}%$(CONFIG_FILE)%g" \
|
||||
-e "s%{{Class}}%$(shell echo $(BINARY) | perl -pe 's/(?:\b|-)(\p{Ll})/\u$$1/g')%g" \
|
||||
init/homebrew/$(BINARY).rb.tmpl | tee $(BINARY).rb
|
||||
init/homebrew/formula.rb.tmpl | tee $(BINARY).rb
|
||||
# Extras
|
||||
|
||||
# Run code tests and lint.
|
||||
|
|
|
|||
|
|
@ -0,0 +1,20 @@
|
|||
# Systemd service unit for {{BINARY}}.
|
||||
|
||||
[Unit]
|
||||
Description={{BINARY}} - {{DESC}}
|
||||
After=network.target
|
||||
Requires=network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/{{BINARY}} $DAEMON_OPTS
|
||||
EnvironmentFile=-/etc/default/{{BINARY}}
|
||||
EnvironmentFile=-/etc/sysconfig/{{BINARY}}
|
||||
Restart=on-error
|
||||
StandardOutput=syslog
|
||||
StandardError=syslog
|
||||
SyslogIdentifier={{BINARY}}
|
||||
Type=simple
|
||||
User=nobody
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
# Sytemd service unit for unifi-poller.
|
||||
|
||||
[Unit]
|
||||
Description=UniFi Poller - Stores UniFi Metrics in InfluxDB
|
||||
After=network.target
|
||||
Requires=network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/unifi-poller $DAEMON_OPTS
|
||||
EnvironmentFile=-/etc/default/unifi-poller
|
||||
EnvironmentFile=-/etc/sysconfig/unifi-poller
|
||||
Restart=on-error
|
||||
StandardOutput=syslog
|
||||
StandardError=syslog
|
||||
SyslogIdentifier=unifi-poller
|
||||
Type=simple
|
||||
User=nobody
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Loading…
Reference in New Issue