Add a no-redesign semantic layer that makes native Gitea collaboration Hop-first
Hop-State: A_06FN45YJ09WC2QFGJM27VE8 Hop-Proposal: R_06FN45WVVTHC245S2BK503G Hop-Task: T_06FN3MVGY3MT82ESQ89BND0 Hop-Attempt: AT_06FN3MVGY092BFA5MR9C7EG
This commit is contained in:
Executable
+37
@@ -0,0 +1,37 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
env_file=${ENV_FILE:-.env}
|
||||
|
||||
if [ ! -f "$env_file" ]; then
|
||||
echo "missing $env_file; copy .env.example and configure it first" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
docker compose --env-file "$env_file" up -d gitea
|
||||
docker compose --env-file "$env_file" exec -T -u root gitea \
|
||||
mkdir -p /data/gitea/templates/custom /data/gitea/public/assets/js
|
||||
docker compose --env-file "$env_file" cp \
|
||||
deploy/gitea/templates/custom/footer.tmpl \
|
||||
gitea:/data/gitea/templates/custom/footer.tmpl
|
||||
docker compose --env-file "$env_file" cp \
|
||||
deploy/gitea/public/assets/js/hop-native.js \
|
||||
gitea:/data/gitea/public/assets/js/hop-native.js
|
||||
docker compose --env-file "$env_file" exec -T -u root gitea \
|
||||
chown -R git:git /data/gitea/templates /data/gitea/public
|
||||
docker compose --env-file "$env_file" exec -T -u git \
|
||||
-e GITEA____APP_NAME=Hop gitea \
|
||||
gitea --config /data/gitea/conf/app.ini config edit-ini --in-place --apply-env
|
||||
docker compose --env-file "$env_file" restart gitea
|
||||
|
||||
attempt=0
|
||||
until curl --fail --silent http://localhost:3000/api/healthz >/dev/null; do
|
||||
attempt=$((attempt + 1))
|
||||
if [ "$attempt" -ge 30 ]; then
|
||||
echo "Gitea did not become healthy" >&2
|
||||
exit 1
|
||||
fi
|
||||
sleep 1
|
||||
done
|
||||
|
||||
echo "Hop-native Gitea semantics installed at http://localhost:3000"
|
||||
Reference in New Issue
Block a user