deemix-docker/root/etc/cont-init.d/10-fix_folders

15 lines
502 B
Plaintext
Raw Normal View History

2021-05-29 23:10:34 +00:00
#!/usr/bin/with-contenv bash
# test write access to download and config folder and test internet connectivity
printf '[cont-init.d] Fixing Folder Permissions\n'
chown -R abc:abc /config
2022-02-10 15:29:37 +00:00
chown -R abc:abc /downloads
2021-05-29 23:10:34 +00:00
# Fix misconfigured download locations. The container's download map is always /downloads.
if [ -f "/config/config.json" ]; then
jq '.downloadLocation = "/downloads"' /config/config.json > tmp.$$.json && mv tmp.$$.json /config/config.json
chown abc:abc /config/config.json
fi