aboutsummaryrefslogtreecommitdiffstats
path: root/gitolite-cgit
diff options
context:
space:
mode:
authorJesús <heckyel@hyperbola.info>2021-07-09 22:57:41 -0500
committerJesús <heckyel@hyperbola.info>2021-07-09 22:57:41 -0500
commit58ad76ba54f4bc0892736bd0ec08bb3c03c5c92a (patch)
treeb555f84568adf0824b598f6f55ea3aaa33277865 /gitolite-cgit
parent1010d9d358d2f0e427c56c153d0c52eefc15d2c7 (diff)
downloadgitolite-cgit-docker-58ad76ba54f4bc0892736bd0ec08bb3c03c5c92a.tar.lz
gitolite-cgit-docker-58ad76ba54f4bc0892736bd0ec08bb3c03c5c92a.tar.xz
gitolite-cgit-docker-58ad76ba54f4bc0892736bd0ec08bb3c03c5c92a.zip
fix directory path, alpine used /etc/nginx/http.d for nginx files
Diffstat (limited to 'gitolite-cgit')
-rwxr-xr-xgitolite-cgit/entrypoint.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/gitolite-cgit/entrypoint.sh b/gitolite-cgit/entrypoint.sh
index 79b9cc1..6ba1ada 100755
--- a/gitolite-cgit/entrypoint.sh
+++ b/gitolite-cgit/entrypoint.sh
@@ -15,12 +15,12 @@ if [ ! -f "/var/lib/git/.ssh/authorized_keys" ]; then
rm "/tmp/$SSH_KEY_NAME.pub"
fi
-if [ ! -d /etc/nginx/conf.d ]; then
- install -d -m755 /etc/nginx/conf.d || true
+if [ ! -d /etc/nginx/http.d ]; then
+ install -d -m755 /etc/nginx/http.d || true
fi
# Init container
-if [ ! -f /etc/nginx/conf.d/cgit.conf ]; then
+if [ ! -f /etc/nginx/http.d/cgit.conf ]; then
# enable random git password
GIT_PASSWORD=$(date +%s | sha256sum | base64 | head -c 32)
echo "git:$GIT_PASSWORD" | chpasswd
@@ -193,7 +193,8 @@ EOF
# /usr/lib/cgit/filters/syntax-highlighting.sh
# Nginx configuration
- cat > /etc/nginx/conf.d/cgit.conf <<- EOF
+ rm -v /etc/nginx/http.d/default.conf || true
+ cat > /etc/nginx/http.d/cgit.conf <<- EOF
server {
listen 80 default_server;
server_name localhost;