diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 7214b2b..a16b73d 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -42,7 +42,7 @@ jobs: context: . push: false load: true - tags: git.stanrunge.dev/stan/personal-website:${{ github.sha }} + tags: git.stanrunge.dev/stan/website:${{ github.sha }} build-args: | GIT_SHA=${{ github.sha }} @@ -50,7 +50,7 @@ jobs: if: github.event_name == 'push' run: | set -euo pipefail - image="git.stanrunge.dev/stan/personal-website:${{ github.sha }}" + image="git.stanrunge.dev/stan/website:${{ github.sha }}" docker save "$image" | ssh -o BatchMode=yes deploy@172.17.0.1 'sudo docker load' - name: Back up, migrate and deploy diff --git a/README.md b/README.md index 0a9e640..abf9284 100644 --- a/README.md +++ b/README.md @@ -378,7 +378,7 @@ After registering, promote your account (ID shown on `/account`): ```sh sudo docker run --rm --network backend --env-file /etc/personal-website/prod.env \ - git.stanrunge.dev/stan/personal-website: bun scripts/set-admin.ts admin + git.stanrunge.dev/stan/website: bun scripts/set-admin.ts admin ``` No public signup grants admin privileges. diff --git a/docs/house-tracker.md b/docs/house-tracker.md index 8d4e3d2..76e1d33 100644 --- a/docs/house-tracker.md +++ b/docs/house-tracker.md @@ -91,7 +91,7 @@ newer; older versions cannot read this repository's lockfile. Use `bun upgrade` if needed. ```sh -git clone https://git.stanrunge.dev/stan/personal-website ~/house-worker +git clone https://git.stanrunge.dev/stan/website ~/house-worker cd ~/house-worker && bun install --frozen-lockfile cat > house.env <<'EOF' HOUSE_API_URL=https://stanrunge.dev diff --git a/scripts/deploy-remote.sh b/scripts/deploy-remote.sh index 9f4b8b4..bedd9bb 100644 --- a/scripts/deploy-remote.sh +++ b/scripts/deploy-remote.sh @@ -16,8 +16,15 @@ origin=https://stanrunge.dev environment=/etc/personal-website/prod.env environment_name=production -image="git.stanrunge.dev/stan/personal-website:$sha" +image="git.stanrunge.dev/stan/website:$sha" compose="$directory/compose.prod.yml" +# Images built before the repo rename (stan/personal-website -> stan/website) keep +# their old local name; retag so rollbacks to those SHAs still work. +legacy_image="git.stanrunge.dev/stan/personal-website:$sha" +if ! sudo docker image inspect "$image" >/dev/null 2>&1 && + sudo docker image inspect "$legacy_image" >/dev/null 2>&1; then + sudo docker tag "$legacy_image" "$image" +fi if ! sudo docker image inspect "$image" >/dev/null 2>&1; then echo "Image $image is not on this host" >&2; exit 1 fi diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index f9a7ce2..1f77433 100755 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -374,7 +374,7 @@ > source