diff --git a/script.sh b/script.sh index 5b8291b..e425e2b 100644 --- a/script.sh +++ b/script.sh @@ -14,9 +14,15 @@ else exit 1 fi +# Get app url +FILE=/app/heroku-app.txt +ROOT_URL=$(grep -oP '(?<=^ROOT_URL\s*=\s*).+' $FILE) + +# Custom configuration mkdir -p /var/lib/gitea/custom/conf # printf "[server]\nDOMAIN = $DOMAIN\n" > /var/lib/gitea/custom/conf/app.ini +printf "[server]\nROOT_URL = $ROOT_URL\n" > /var/lib/gitea/custom/conf/app.ini printf "[database]\nDB_TYPE = $DB_TYPE\nHOST = $HOST\nNAME = $NAME\nUSER = $USER\nPASSWD = $PASSWD\n" >> /var/lib/gitea/custom/conf/app.ini /usr/local/bin/gitea web -port $PORT \ No newline at end of file