Skip to content

Commit d768a70

Browse files
committed
write permission check
1 parent f549757 commit d768a70

File tree

1 file changed

+5
-1
lines changed
  • root/etc/s6-overlay/s6-rc.d/init-sma-config

1 file changed

+5
-1
lines changed

root/etc/s6-overlay/s6-rc.d/init-sma-config/run

+5-1
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,10 @@ chown -R abc:abc ${SMA_PATH}
185185
chmod -R 775 ${SMA_PATH}/*.sh
186186

187187
# update autoprocess
188-
${SMA_PATH}/venv/bin/python3 ${SMA_PATH}/update.py
188+
if [ -w "$SMA_PATH/config/autoProcess.ini" ]; then
189+
${SMA_PATH}/venv/bin/python3 ${SMA_PATH}/update.py
190+
else
191+
echo "${echoprefix} autoProcess.ini does not have write permission, it will need to be configured manually"
192+
fi
189193

190194
exit $?

0 commit comments

Comments
 (0)