updated to 'pi' home directory

This commit is contained in:
xdrm-brackets 2018-01-29 18:32:48 +01:00
parent 8e7d0a4733
commit f2fb0532a8
2 changed files with 5 additions and 3 deletions

View File

@ -6,8 +6,10 @@ Type=simple
Restart=always Restart=always
User=pi User=pi
Group=pi Group=pi
ExecStartPre=/usr/bin/sudo -u sats git clone --recursive -b master ssh://smmp-server/satsd/debug /service/debug ExecStartPre=/usr/bin/sudo -u sats git clone --recursive -b master ssh://smmp-server/satsd/debug /home/pi/debug
ExecStart=/bin/bash /service/debug/sats/main %i ExecStartPre=/usr/bin/sudo chown -R pi:pi /home/pi/debug
ExecStartPre=/usr/bin/sudo chmod -R 750 /home/pi/debug
ExecStart=/bin/bash /home/pi/debug/sats/main %i
ExecStop=/bin/sleep 10 ExecStop=/bin/sleep 10
[Install] [Install]

View File

@ -10,7 +10,7 @@ ROOT=`dirname $ROOT`;
test $# -lt 1 && echo -e "ERR: Missing argument\n\n\tSATS_ID\tThe id for the bash-socket\n" && exit 1; test $# -lt 1 && echo -e "ERR: Missing argument\n\n\tSATS_ID\tThe id for the bash-socket\n" && exit 1;
# (2) Create config dir (if doesn't exist) # # (2) Create config dir (if doesn't exist) #
test ! -d $ROOT/config && sudo -u sats ( mkdir $ROOT/config; chown sats:pi $ROOT/config; chmod 770 $ROOT/config ); test ! -d $ROOT/config && ( mkdir $ROOT/config; sudo chown sats:pi $ROOT/config; sudo chmod 770 $ROOT/config );
# (2) Start server in background (keep PID) # (2) Start server in background (keep PID)
#--------------------------------------------------------# #--------------------------------------------------------#