wolf: fix manage.sh apps permission denied on /etc/wolf/cfg/config.toml
config.toml is root-owned (Wolf container writes it as root). manage.sh runs as the regular user, so python3 and grep against the file need sudo. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01D8ckUJQtj1pH8jtAddBDZs
This commit is contained in:
+2
-2
@@ -938,7 +938,7 @@ case "$1" in
|
|||||||
# Show which apps are already installed and what's available
|
# Show which apps are already installed and what's available
|
||||||
echo ""
|
echo ""
|
||||||
echo " Checking current Wolf config..."
|
echo " Checking current Wolf config..."
|
||||||
INSTALLED=$(grep "^ name = 'Wolf" "$WOLF_CFG" 2>/dev/null | sed "s/.*name = '//;s/'//" | tr '\n' ' ')
|
INSTALLED=$(sudo grep "^ name = 'Wolf" "$WOLF_CFG" 2>/dev/null | sed "s/.*name = '//;s/'//" | tr '\n' ' ')
|
||||||
[ -n "$INSTALLED" ] && echo " Already installed: $INSTALLED" || echo " No Wolf apps installed yet."
|
[ -n "$INSTALLED" ] && echo " Already installed: $INSTALLED" || echo " No Wolf apps installed yet."
|
||||||
echo ""
|
echo ""
|
||||||
echo " Available apps:"
|
echo " Available apps:"
|
||||||
@@ -988,7 +988,7 @@ case "$1" in
|
|||||||
echo " Applying: ${APP_KEYS:-none}"
|
echo " Applying: ${APP_KEYS:-none}"
|
||||||
[ -z "$APP_KEYS" ] && exit 0
|
[ -z "$APP_KEYS" ] && exit 0
|
||||||
|
|
||||||
python3 - "$GAME_DIR" "$WOLF_CFG" $APP_KEYS << 'PYEOF'
|
sudo python3 - "$GAME_DIR" "$WOLF_CFG" $APP_KEYS << 'PYEOF'
|
||||||
import sys, json
|
import sys, json
|
||||||
|
|
||||||
games = sys.argv[1].rstrip('/')
|
games = sys.argv[1].rstrip('/')
|
||||||
|
|||||||
Reference in New Issue
Block a user