We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 98ea1a5 commit d0f614aCopy full SHA for d0f614a
docker/etc/s6/gitea/setup
@@ -39,5 +39,8 @@ if [ ! -f /data/gitea/conf/app.ini ]; then
39
envsubst < /etc/templates/app.ini > /data/gitea/conf/app.ini
40
fi
41
42
-chown -R ${USER}:git /data/gitea /app/gitea /data/git
+# only chown if current owner is not already the gitea ${USER}. No recursive check to save time
43
+if ! [[ $(ls -ld /data/gitea | awk '{print $3}') = ${USER} ]]; then chown -R ${USER}:git /data/gitea; fi
44
+if ! [[ $(ls -ld /app/gitea | awk '{print $3}') = ${USER} ]]; then chown -R ${USER}:git /app/gitea; fi
45
+if ! [[ $(ls -ld /data/git | awk '{print $3}') = ${USER} ]]; then chown -R ${USER}:git /data/git; fi
46
chmod 0755 /data/gitea /app/gitea /data/git
0 commit comments