Bug 197235 - [NEW PORT] sysutils/s6 daemontools-like supervision suite
Summary: [NEW PORT] sysutils/s6 daemontools-like supervision suite
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Pawel Pekala
Depends on: 197234
  Show dependency treegraph
Reported: 2015-02-01 06:34 UTC by Colin Booth
Modified: 2015-02-23 22:18 UTC (History)
1 user (show)

See Also:

s6 supervision suite, submitted at latest release version (11.06 KB, application/x-shar)
2015-02-01 06:34 UTC, Colin Booth
no flags Details
Updated port submission (11.33 KB, application/x-shar)
2015-02-05 18:29 UTC, Colin Booth
no flags Details
Updated port submission (11.51 KB, application/x-shar)
2015-02-06 17:46 UTC, Colin Booth
no flags Details
s6 v2.1.1.1 version bump (11.33 KB, application/x-shar)
2015-02-21 04:45 UTC, Colin Booth
no flags Details
Fixed makefile, removed absolute paths (10.51 KB, application/x-shar)
2015-02-22 17:13 UTC, Colin Booth
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Colin Booth 2015-02-01 06:34:13 UTC
Created attachment 152432 [details]
s6 supervision suite, submitted at latest release version

The s6 supervision suite is similar to daemontools and runit. It is designed as an init replacement but works equally well as a non-pid 1 supervision daemon. This port doesn't install any of the support scripts needed to replace init since it's probably unwise to replace core system functionality with something out of the ports collection.
Comment 1 Colin Booth 2015-02-05 18:29:12 UTC
Created attachment 152597 [details]
Updated port submission

New port submission. Now handles user changed files, scan directories, and a few other things. Also includes makefile cleanup.
Comment 2 Colin Booth 2015-02-06 17:46:48 UTC
Created attachment 152629 [details]
Updated port submission
Comment 3 Colin Booth 2015-02-21 04:45:23 UTC
Created attachment 153264 [details]
s6 v2.1.1.1 version bump

Version bump for pending port submission
Comment 4 Pawel Pekala freebsd_committer 2015-02-21 16:11:58 UTC
Few things to fix:

X+#!/usr/local/bin/execlineb -S0

This will break if install PREFIX != /usr/local, /usr/bin/env can be used here:

#!/usr/bin/env execlineb -S0

there are more places with this mistake.

X+/usr/local/bin/foreground { /usr/sbin/chown nobody:nogroup ${SCANROOT}/s6-svscan-log/fifo }
X+/usr/local/bin/redirfd -wnb 1 ${SCANROOT}/s6-svscan-log/fifo
X+/usr/local/bin/fdmove -c 2 1
X+/usr/local/bin/s6-envdir -I ${SCANROOT}/.s6-svscan/env
X+/usr/local/bin/exec -a s6-svscan
X+/usr/local/bin/s6-svscan -t0 ${SCANROOT}

Again, will fail if PREFIX != /usr/local either don't use full path or
use SUB_LIST to set correct full path.

XAuthor:	Laurent G. Bercot <ska-skaware@skarnet.org>

We don't put authors in pkg-descr anymore.

X# Created by: Sergei Kolobov <sergei@kolobov.com>

Here should be author of the port, you.


gmake here

X	cd ${WRKSRC} && CC=${CC} ./configure ${CONFIGURE_ARGS}

No need to declare this target use HAS_CONFIGURE=yes.
Comment 5 Colin Booth 2015-02-22 01:32:48 UTC
(In reply to Pawel Pekala from comment #4)
Thanks. I'd fixed some of those already in the previous submission and it looks like I replaced the Makefile with a worse one. I'll fix the hard-coded paths and replace that Makefile with one that's actually right.
Comment 6 Colin Booth 2015-02-22 17:13:56 UTC
Created attachment 153322 [details]
Fixed makefile, removed absolute paths

Fixed makefile to remove regressions.

Absolute path's that can be replaced with LOCALBASE and PREFIX have been switched.

I ran into some issues trying to figure the right way forward with that cleanup, since the path passed via the environment to s6-svscan may be incorrect if LOCALBASE != PREFIX. I think I did the closest-to-right thing without adding in extra logic but I'm not sure. Either way the point is mostly stylistic as the only place where it would matter within this package (s6-svscanboot) uses full paths all the way down the line.
Comment 7 commit-hook freebsd_committer 2015-02-23 22:14:18 UTC
A commit references this bug:

Author: pawel
Date: Mon Feb 23 22:14:14 UTC 2015
New revision: 379714
URL: https://svnweb.freebsd.org/changeset/ports/379714

  s6 is a small suite of programs for UNIX, designed to allow process
  supervision (a.k.a service supervision), in the line of daemontools and

  WWW: http://www.skarnet.org/software/s6/

  PR:		197235
  Submitted by:	Colin Booth <colin@heliocat.net>

Comment 8 commit-hook freebsd_committer 2015-02-23 22:18:20 UTC
A commit references this bug:

Author: pawel
Date: Mon Feb 23 22:17:55 UTC 2015
New revision: 46286
URL: https://svnweb.freebsd.org/changeset/doc/46286

  For sysutils/s6

  PR:		197235