diff options
author | Christian Pointner <equinox@helsinki.at> | 2011-04-05 13:44:40 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2011-04-05 13:44:40 (GMT) |
commit | 5c642ab1c39fde2b6515ab0653fd084a439077a0 (patch) | |
tree | dfdf6146260fb39722cbcc1b4db97bc1526118c5 | |
parent | 99c07fae615a1f44a2eb24eb973700931017b248 (diff) |
added nopsyncstated to debian package
-rw-r--r-- | rhnop-client/Makefile | 4 | ||||
-rw-r--r-- | rhnop-client/debian/rhnop-client.state.runit | 5 | ||||
-rw-r--r-- | rhnop-client/debian/rhnop-client.state.runit.log | 9 | ||||
-rwxr-xr-x | rhnop-client/debian/rules | 8 |
4 files changed, 26 insertions, 0 deletions
diff --git a/rhnop-client/Makefile b/rhnop-client/Makefile index f85b59d..4e84c7a 100644 --- a/rhnop-client/Makefile +++ b/rhnop-client/Makefile @@ -46,6 +46,9 @@ install-bin: $(EXECUTABLE) $(INSTALL) -m 755 $(EXECUTABLE) $(DESTDIR)$(BINDIR) $(SED) -e 's#^conffile = "nopcollectd#conffile = "$(ETCDIR)/rhnop/nopcollectd#' -i $(DESTDIR)$(BINDIR)/$(EXECUTABLE) $(SED) -e 's#_rhnoplibdir_/?.lua#$(LIBDIR)/?.lua#' -i $(DESTDIR)$(BINDIR)/$(EXECUTABLE) + $(INSTALL) -m 755 nopsysstated $(DESTDIR)$(BINDIR) + $(SED) -e 's#^conffile = "nopsysstated#conffile = "$(ETCDIR)/rhnop/nopsysstated#' -i $(DESTDIR)$(BINDIR)/nopsysstated + $(SED) -e 's#_rhnoplibdir_/?.lua#$(LIBDIR)/?.lua#' -i $(DESTDIR)$(BINDIR)/nopsysstated install-lib: $(INSTALL) -d $(DESTDIR)$(LIBDIR) @@ -55,6 +58,7 @@ install-lib: install-etc: $(INSTALL) -d $(DESTDIR)$(ETCDIR)/rhnop $(INSTALL) -m 640 nopcollectd.*.conf $(DESTDIR)$(ETCDIR)/rhnop + $(INSTALL) -m 640 nopsysstated.conf $(DESTDIR)$(ETCDIR)/rhnop uninstall: remove diff --git a/rhnop-client/debian/rhnop-client.state.runit b/rhnop-client/debian/rhnop-client.state.runit new file mode 100644 index 0000000..f044abf --- /dev/null +++ b/rhnop-client/debian/rhnop-client.state.runit @@ -0,0 +1,5 @@ +#!/bin/sh +set -e + +exec 2>&1 +exec chpst -u rhnop:rhnop /usr/bin/nopsysstated diff --git a/rhnop-client/debian/rhnop-client.state.runit.log b/rhnop-client/debian/rhnop-client.state.runit.log new file mode 100644 index 0000000..7a67bb3 --- /dev/null +++ b/rhnop-client/debian/rhnop-client.state.runit.log @@ -0,0 +1,9 @@ +#!/bin/sh +set -e + +LOG_D="/var/log/nopsysstated/" +if [ ! -d "$LOG_D" ]; then + mkdir -p -m0750 "$LOG_D" +fi +chown root:adm "$LOG_D" +exec chpst -u root:adm svlogd -tt "$LOG_D" diff --git a/rhnop-client/debian/rules b/rhnop-client/debian/rules index 63f5fdd..ef73f66 100755 --- a/rhnop-client/debian/rules +++ b/rhnop-client/debian/rules @@ -44,6 +44,11 @@ install: build cp $(CURDIR)/debian/rhnop-client.standby.runit $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.standby/run ln -s /var/run/sv.rhnop-client.standby.log/ $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.standby/log/supervise cp $(CURDIR)/debian/rhnop-client.standby.runit.log $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.standby/log/run + mkdir -p $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.state/log + ln -s /var/run/sv.rhnop-client.state/ $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.state/supervise + cp $(CURDIR)/debian/rhnop-client.state.runit $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.state/run + ln -s /var/run/sv.rhnop-client.state.log/ $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.state/log/supervise + cp $(CURDIR)/debian/rhnop-client.state.runit.log $(CURDIR)/debian/rhnop-client/etc/sv/rhnop-client.state/log/run # Build architecture-independent files here. binary-indep: install @@ -61,10 +66,13 @@ binary-arch: install dh_compress dh_fixperms chmod 640 debian/rhnop-client/etc/rhnop/nopcollectd.*.conf + chmod 640 debian/rhnop-client/etc/rhnop/nopsysstated.conf chmod 755 debian/rhnop-client/etc/sv/rhnop-client.master/run chmod 755 debian/rhnop-client/etc/sv/rhnop-client.master/log/run chmod 755 debian/rhnop-client/etc/sv/rhnop-client.standby/run chmod 755 debian/rhnop-client/etc/sv/rhnop-client.standby/log/run + chmod 755 debian/rhnop-client/etc/sv/rhnop-client.state/run + chmod 755 debian/rhnop-client/etc/sv/rhnop-client.state/log/run dh_installdeb dh_shlibdeps dh_gencontrol |