Skip to content
Snippets Groups Projects
Commit b60014d9 authored by ale's avatar ale
Browse files

install static content

parent 6bc67b14
No related branches found
Tags
No related merge requests found
......@@ -25,6 +25,7 @@ SVCDIR = $(DESTDIR)/etc/svc
dh $@
override_dh_install:
# Build the binary
install -m 755 -o root -g root -d $(DESTDIR)/usr/bin
(tmpdir=$$(mktemp -d) ; \
export GOPATH=$$tmpdir ; unset GOBIN ; \
......@@ -37,14 +38,25 @@ override_dh_install:
done ; \
rm -fr $$tmpdir)
install -d -m 755 -o root -g root $(SVCDIR)
# Install the static files and templates for the HTTP dashboard.
install -d -m 755 -o root -g root $(DESTDIR)/usr/share/radioai
install -m 644 -o root -g root debian/services/lib.sh \
install -d -m 755 -o root -g root $(DESTDIR)/usr/share/radioai/htdocs/static
(for f in $(CURDIR)/fe/static/* ; do \
install -o root -g root -m 644 $$f $(DESTDIR)/usr/share/radioai/htdocs/static/ ; \
done)
install -d -m 755 -o root -g root $(DESTDIR)/usr/share/radioai/htdocs/templates
(for f in $(CURDIR)/fe/templates/*.html ; do \
install -o root -g root -m 644 $$f $(DESTDIR)/usr/share/radioai/htdocs/templates/ ; \
done)
# Install runit service runners.
install -d -m 755 -o root -g root $(SVCDIR)
install -m 644 -o root -g root $(CURDIR)/debian/services/lib.sh \
$(DESTDIR)/usr/share/radioai/lib.sh
(for f in radiod redirectord ; do \
install -d -o root -g root $(SVCDIR)/$$f ; \
install -d -o root -g root $(SVCDIR)/$$f/log ; \
install -m 755 -o root -g root debian/services/$$f \
install -m 755 -o root -g root $(CURDIR)/debian/services/$$f \
$(SVCDIR)/$$f/run ; \
echo -e '#!/bin/sh\nexec chpst -u log svlogd -tt /var/log/radioai/'$$f > \
$(SVCDIR)/$$f/log/run ; \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment