consistent ownership/permissions for /run/service-state/**
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
, ppp
|
||||
, pppoe
|
||||
, writeAshScript
|
||||
, serviceFns
|
||||
} :
|
||||
let
|
||||
inherit (liminix.services) longrun;
|
||||
@@ -17,16 +18,15 @@ interface: {
|
||||
let
|
||||
name = "${interface.device}.pppoe";
|
||||
ip-up = writeAshScript "ip-up" {} ''
|
||||
outputs=/run/service-state/${name}/
|
||||
mkdir -p $outputs
|
||||
(cd $outputs
|
||||
echo $1 > ifname
|
||||
echo $2 > tty
|
||||
echo $3 > speed
|
||||
echo $4 > address
|
||||
echo $5 > peer-address
|
||||
echo $DNS1 > ns1
|
||||
echo $DNS1 > ns2
|
||||
. ${serviceFns}
|
||||
(cd $(mkoutputs ${name}); umask 0027
|
||||
echo $1 > ifname
|
||||
echo $2 > tty
|
||||
echo $3 > speed
|
||||
echo $4 > address
|
||||
echo $5 > peer-address
|
||||
echo $DNS1 > ns1
|
||||
echo $DNS2 > ns2
|
||||
)
|
||||
echo >/proc/self/fd/10
|
||||
'';
|
||||
|
Reference in New Issue
Block a user