Align install.sh defaults with afterclone; fix inverted --no-verify-ssl

- Defaults now match run_player-afterclone.sh and the deployed device:
  edit_feature_enabled=true, verify_ssl=false (use_https=false unchanged)
- Fix inverted logic: --no-verify-ssl previously set verify_ssl=True
- Add --verify-ssl flag for parity with run_player-afterclone.sh
This commit is contained in:
SKE087
2026-10-14 23:35:35 +03:00
parent 31807f37bf
commit c221f76a71
+15 -7
View File
@@ -19,7 +19,8 @@
# -n, --name NAME Screen/player name # -n, --name NAME Screen/player name
# -k, --key KEY Quick-connect / auth key # -k, --key KEY Quick-connect / auth key
# --https Enable HTTPS # --https Enable HTTPS
# --no-verify-ssl Disable SSL verification # --verify-ssl Enable SSL certificate verification
# --no-verify-ssl Disable SSL verification (default)
# -o, --orientation Landscape or Portrait # -o, --orientation Landscape or Portrait
# --touch Enable touch input # --touch Enable touch input
# -r, --resolution WxH Max resolution # -r, --resolution WxH Max resolution
@@ -154,7 +155,8 @@ usage() {
echo " -n, --name NAME Screen/player name" echo " -n, --name NAME Screen/player name"
echo " -k, --key KEY Quick-connect / auth key" echo " -k, --key KEY Quick-connect / auth key"
echo " --https Enable HTTPS for server communication" echo " --https Enable HTTPS for server communication"
echo " --no-verify-ssl Disable SSL certificate verification" echo " --verify-ssl Enable SSL certificate verification"
echo " --no-verify-ssl Disable SSL certificate verification (default)"
echo " -o, --orientation Landscape or Portrait (default: Landscape)" echo " -o, --orientation Landscape or Portrait (default: Landscape)"
echo " --touch Enable touch input" echo " --touch Enable touch input"
echo " -r, --resolution WxH Max resolution (default: 1920x1080)" echo " -r, --resolution WxH Max resolution (default: 1920x1080)"
@@ -206,6 +208,10 @@ while [ $# -gt 0 ]; do
USE_HTTPS="true" USE_HTTPS="true"
shift shift
;; ;;
--verify-ssl)
VERIFY_SSL="true"
shift
;;
--no-verify-ssl) --no-verify-ssl)
VERIFY_SSL="false" VERIFY_SSL="false"
shift shift
@@ -598,7 +604,9 @@ edit_val = os.environ.get('EDIT_ENABLED', '')
if https_val: if https_val:
config['use_https'] = https_val.lower() == 'true' config['use_https'] = https_val.lower() == 'true'
if verify_val: if verify_val:
config['verify_ssl'] = verify_val.lower() == 'false' # VERIFY_SSL holds the requested verification state ("true"/"false").
# (Previously this was inverted: '--no-verify-ssl' set verify_ssl=True.)
config['verify_ssl'] = verify_val.lower() != 'false'
if edit_val: if edit_val:
config['edit_feature_enabled'] = edit_val.lower() == 'true' config['edit_feature_enabled'] = edit_val.lower() == 'true'
@@ -606,9 +614,9 @@ config.setdefault('port', '8080')
config.setdefault('orientation', 'Landscape') config.setdefault('orientation', 'Landscape')
config.setdefault('touch', 'True') config.setdefault('touch', 'True')
config.setdefault('max_resolution', '1920x1080') config.setdefault('max_resolution', '1920x1080')
config.setdefault('edit_feature_enabled', False) config.setdefault('edit_feature_enabled', True)
config.setdefault('use_https', False) config.setdefault('use_https', False)
config.setdefault('verify_ssl', True) config.setdefault('verify_ssl', False)
with open(config_file, 'w') as f: with open(config_file, 'w') as f:
json.dump(config, f, indent=2) json.dump(config, f, indent=2)
@@ -625,9 +633,9 @@ PYEOF
"orientation": "Landscape", "orientation": "Landscape",
"touch": "True", "touch": "True",
"max_resolution": "1920x1080", "max_resolution": "1920x1080",
"edit_feature_enabled": false, "edit_feature_enabled": true,
"use_https": false, "use_https": false,
"verify_ssl": true "verify_ssl": false
} }
EOF EOF
echo "Default config template created" echo "Default config template created"