dot

packages and services management
Log | Files | Refs | README

commit 6321ed2cfe6b235d710128d6a88679d64d616d58
parent 8da6ce6f2d54c06d24d788d102231b7dff4e603d
Author: Josuah Demangeon <mail@josuah.net>
Date:   Fri,  9 Nov 2018 00:15:37 +0100

bin/service-* adjust splitting and stripping

Diffstat:
Mbin/service-enable | 5+++--
Mbin/service-load | 2+-
Mbin/service-reload | 2+-
Mbin/service-restart | 2+-
Mbin/service-start | 2+-
Mbin/service-status | 2+-
Mbin/service-stop | 2+-
Ms6/ssh-agent/x/run | 4+++-
8 files changed, 12 insertions(+), 9 deletions(-)

diff --git a/bin/service-enable b/bin/service-enable @@ -14,9 +14,10 @@ define -n log ${dst}-log importas log log if { rm -rf $dst $log } if { s6-hiercopy /etc/s6/s6-log/x $log } if { s6-hiercopy /etc/s6/${dir}/x $dst } -if { s6-hiercopy /etc/s6/${src} $dst } +if { s6-hiercopy /etc/s6/${src} $dst } if { redirfd -w 1 ${dst}/producer-for echo $log } if { redirfd -w 1 ${log}/consumer-for echo $dst } -if { redirfd -w 1 ${log}/env/SERVICE echo $dst } +if { redirfd -w 1 ${log}/pipeline-name echo $dst } +if { redirfd -w 1 ${log}/env/SERVICE echo $dst } if { pipeline { echo $dst } sort -u -o ok-all/contents ok-all/contents - } if { pipeline { echo $log } sort -u -o ok-all/contents ok-all/contents - } diff --git a/bin/service-load b/bin/service-load @@ -1,6 +1,6 @@ #!/usr/bin/env execlineb -backtick t { s6-clock } importas -n t t +backtick -n t { s6-clock } importas t t if { s6-rc-compile /var/s6/compiled$t /var/s6/current } if { s6-rc-update -l /var/s6/live /var/s6/compiled$t } if { s6-ln -nsf /var/s6/compiled$t /var/s6/compiled } diff --git a/bin/service-reload b/bin/service-reload @@ -1,4 +1,4 @@ #!/usr/bin/env execlineb -forbacktickx x { pipeline { dollarat } tr / - } importas -n x x +forbacktickx -n x { pipeline { dollarat } tr / - } importas x x s6-svc -h /run/s6/$x diff --git a/bin/service-restart b/bin/service-restart @@ -1,5 +1,5 @@ #!/usr/bin/env execlineb -backtick @ { pipeline { dollarat } tr / - } importas -n @ @ +backtick -n @ { pipeline { dollarat } tr / - } importas @ @ if { service-stop $@ } if { service-start $@ } diff --git a/bin/service-start b/bin/service-start @@ -1,4 +1,4 @@ #!/usr/bin/env execlineb -backtick @ { pipeline { dollarat } tr / - } importas @ @ +backtick -n @ { pipeline { dollarat } tr / - } importas @ @ s6-rc -l /var/s6/live -u change $@ diff --git a/bin/service-status b/bin/service-status @@ -1,4 +1,4 @@ #!/usr/bin/env execlineb -backtick @ { pipeline { dollarat } tr / - } importas @ @ +backtick -n @ { pipeline { dollarat } tr / - } importas @ @ s6-rc -l /var/s6/live listall $@ diff --git a/bin/service-stop b/bin/service-stop @@ -1,4 +1,4 @@ #!/usr/bin/env execlineb -backtick @ { pipeline { dollarat } tr / - } importas @ @ +backtick -n @ { pipeline { dollarat } tr / - } importas @ @ s6-rc -l /var/s6/live -d change $@ diff --git a/s6/ssh-agent/x/run b/s6/ssh-agent/x/run @@ -6,4 +6,6 @@ s6-envdir env multisubstitute { backtick -n home { homeof $USER } importas home home -ssh-agent -d -a ${home}/.ssh/sock +s6-setuidgid $USER +if { whoami } +ssh-agent -d -a ${home}/.ssh/auth.sock