Repository navigation
fix(bootstrap): refuse a platform still on Gitea, which Forgejo can't open, before changing anything - #135
Open
Teg79 wants to merge 1 commit into
Open
fix(bootstrap): refuse a platform still on Gitea, which Forgejo can't open, before changing anything#135Teg79 wants to merge 1 commit into
Teg79 wants to merge 1 commit into
Conversation
… open, before changing anything Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0182yxsfwRowwnxCfgrQwjnA
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
urbex bootstraprefuses a platform created by urbex 0.1.0, whose forge is still Gitea, before it changes anything (#134).internal/bootstrap/forgeguard.go(new):refuseGiteaPlatformreads the forge's compose file as the GitOps repo keeps it. Every bootstrap copies it there, 0.1.0's included (platform/gitea/compose.yaml). Animage:ofgitea/gitea(with or withoutdocker.io/, by tag or digest) returnsErrPlatformRunsGitea.urbex destroyeach environment (teardown requires it),urbex teardown,urbex bootstrap, push the repos andurbex applyagain. Or stay on 0.1.0.internal/bootstrap/orchestrator.go: the check runs right after the existing machines are listed, whenurbex-giteais among them. It comes before the assets are written, the template, Terraform or Ansible, so nothing is changed and the exit is non-zero.internal/bootstrap/orchestrator_test.go:TestRun_RefusesAPlatformStillOnGitea:docker.io/gitea/gitea:1.24andgitea/gitea@sha256:...are refused too.CHANGELOG.md: under Fixed.Companion: urbforge/urbex#103 (upgrading from 0.1.0 to 0.2.0, and the
cliskill). The CHANGELOG's Breaking/Upgrading are in #133.Why
#134. I reproduced it locally:
codeberg.org/forgejo/forgejo:15.0.11on agitea/gitea:1.24(1.24.7) volume exits with "Your database (migration version: 321) is for a newer Forgejo ... (305)", so a 0.1.0 platform bootstrapped with today'smainlost its forge. Teg's decision: v0.2.0 frommain, with this guard.Tests I ran
mise run test,mise run lint: pass.mise run e2e: passed, 24 steps. Its second bootstrap, on a Forgejo platform, isn't refused.image: gitea/gitea:1.24, from the v0.1.0 tag).Checklist before review
Fixes #134
🤖 Generated with Claude Code
https://claude.ai/code/session_0182yxsfwRowwnxCfgrQwjnA