Handle unwritable browser volume in entrypoint
This commit is contained in:
parent
a477bb3327
commit
e3e6a6f36c
1 changed files with 6 additions and 2 deletions
|
|
@ -16,13 +16,17 @@ rm -f /fgc/data/browser/SingletonLock
|
||||||
# Since this file has to be in the volume (data/browser), we can't do this in Dockerfile.
|
# Since this file has to be in the volume (data/browser), we can't do this in Dockerfile.
|
||||||
mkdir -p /fgc/data/browser
|
mkdir -p /fgc/data/browser
|
||||||
# fix for 'Incorrect response' after solving a captcha correctly - https://github.com/vogler/free-games-claimer/issues/261#issuecomment-1868385830
|
# fix for 'Incorrect response' after solving a captcha correctly - https://github.com/vogler/free-games-claimer/issues/261#issuecomment-1868385830
|
||||||
# echo 'user_pref("privacy.resistFingerprinting", true);' > /fgc/data/browser/user.js
|
# Only write the prefs file when the volume is writable (container runs as non-root).
|
||||||
cat << EOT > /fgc/data/browser/user.js
|
if [ -w /fgc/data/browser ]; then
|
||||||
|
cat << EOT > /fgc/data/browser/user.js
|
||||||
user_pref("privacy.resistFingerprinting", true);
|
user_pref("privacy.resistFingerprinting", true);
|
||||||
// user_pref("privacy.resistFingerprinting.letterboxing", true);
|
// user_pref("privacy.resistFingerprinting.letterboxing", true);
|
||||||
// user_pref("browser.contentblocking.category", "strict");
|
// user_pref("browser.contentblocking.category", "strict");
|
||||||
// user_pref("webgl.disabled", true);
|
// user_pref("webgl.disabled", true);
|
||||||
EOT
|
EOT
|
||||||
|
else
|
||||||
|
echo "Warning: /fgc/data/browser is not writable; skipping user.js creation."
|
||||||
|
fi
|
||||||
# TODO disable session restore message?
|
# TODO disable session restore message?
|
||||||
|
|
||||||
# Remove X server display lock, fix for `docker compose up` which reuses container which made it fail after initial run, https://github.com/vogler/free-games-claimer/issues/31
|
# Remove X server display lock, fix for `docker compose up` which reuses container which made it fail after initial run, https://github.com/vogler/free-games-claimer/issues/31
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue