Browse Source

Set up /var/run/calico and /usr/local/etc/pounce

master
Causal Agent 1 week ago
parent
commit
831e2f1049
Signed by: C. McEnroe <june@causal.agency> GPG Key ID: CEA2F97ADCFCD77C
3 changed files with 12 additions and 3 deletions
  1. 4
    1
      Makefile
  2. 4
    1
      rc.d/calico
  3. 4
    1
      rc.d/pounce

+ 4
- 1
Makefile View File

@@ -10,7 +10,8 @@ LDLIBS = -ltls

BINS = calico pounce
MANS = ${BINS:=.1}
RCS = ${BINS:%=rc.d/%}
RCS = ${BINS:%=rc.d/%}
DIRS = ${ETCDIR}/pounce /var/run/calico

-include config.mk

@@ -43,11 +44,13 @@ install: ${BINS} ${MANS} ${RCS}
install ${BINS} ${PREFIX}/bin
install -m 644 ${MANS} ${MANDIR}/man1
install ${RCS} ${ETCDIR}/rc.d
install -d -m 700 ${DIRS}

uninstall:
rm -f ${BINS:%=${PREFIX}/bin/%}
rm -f ${MANS:%=${MANDIR}/man1/%}
rm -f ${RCS:%=${ETCDIR}/%}
rmdir ${DIRS}

localhost.crt:
printf "[dn]\nCN=localhost\n[req]\ndistinguished_name=dn\n[EXT]\nsubjectAltName=DNS:localhost\nkeyUsage=digitalSignature\nextendedKeyUsage=serverAuth" \

+ 4
- 1
rc.d/calico View File

@@ -11,11 +11,14 @@ rcvar='calico_enable'

load_rc_config "${name}"

: ${calico_enable:="NO"}
: ${calico_enable:='NO'}
: ${calico_path:="/var/run/${name}"}
calico_flags="${calico_flags} ${calico_path}"

command='/usr/sbin/daemon'
procname='/usr/local/bin/calico'
pidfile="/var/run/${name}.pid"
required_dirs=$calico_path

child_flags=$calico_flags
child_user=$calico_user

+ 4
- 1
rc.d/pounce View File

@@ -13,11 +13,13 @@ sig_reload='USR1'

load_rc_config "${name}"

: ${pounce_enable:="NO"}
: ${pounce_enable:='NO'}
: ${pounce_chdir:="/usr/local/etc/${name}"}

command='/usr/sbin/daemon'
pidprefix="/var/run/${name}"
pidfile="${pidprefix}.pid"
required_dirs=$pounce_chdir

child_command='/usr/local/bin/pounce'
child_pidfile="${pidprefix}.child.pid"
@@ -29,6 +31,7 @@ if [ -n "$2" ]; then
child_pidfile="${pidprefix}.${profile}.child.pid"
eval pounce_enable="\${pounce_${profile}_enable:-${pounce_enable}}"
eval pounce_flags="\${pounce_${profile}_flags:-${pounce_flags}}"
eval pounce_chdir="\${pounce_${profile}_chdir:-${pounce_chdir}}"
eval pounce_user="\${pounce_${profile}_user:-${pounce_user}}"
else
echo "$0: extra argument ignored"

Loading…
Cancel
Save