forked from DeckerSU/KomodoOcean
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathentrypoint.sh
More file actions
executable file
·25 lines (20 loc) · 827 Bytes
/
Copy pathentrypoint.sh
File metadata and controls
executable file
·25 lines (20 loc) · 827 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/usr/bin/env bash
set -euo pipefail
# By default, `kmdclassicd` inside the container runs as the `nobody:nogroup` user. All files
# created by the daemon in the data folder will also have these access privileges. To
# bypass the `nobody:nogroup` ownership check on the data folder, you can use the
# `-no-ownership-check` key.
nocheck=0
for arg in "$@"
do
if [[ "$arg" == "--no-ownership-check" ]] || [[ "$arg" == "-no-ownership-check" ]]; then
nocheck=1
break
fi
done
if [[ "$nocheck" -eq 0 && "$(stat -c '%u:%g' /data)" != "65534:65534" ]]; then
echo "Folder mounted at /data is not owned by nobody:nogroup, please change its permissions on the host with 'sudo chown -R 65534:65534 path/to/komodo-data'."
exit 1
fi
/app/fetch-params.sh
exec /app/kmdclassicd -datadir=/data/.kmdclassic "$@"