Repository navigation
feat(docker): one-line installer and release Compose file - #384
Merged
Merged
Conversation
Add scripts/install.sh, a one-line installer that checks Docker and Compose v2, installs into ~/opencode-manager (override with OCM_DIR), prompts for an optional OpenCode config import, a repos folder mount and LAN sign-in, then pulls and starts the published image. - Add docker-compose.release.yml, which runs the published image under the Compose project name ocm; a checkout's docker-compose.yml keeps building from source - Generate AUTH_SECRET on first container start and persist it to the data volume when unset, so Compose installs need no .env - Refuse to install over a source checkout or beside an existing install, so volumes and the auth secret are not silently replaced - Test the installer, entrypoint secret handling, and the two Compose files staying in step
Contributor
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
📒 Files selected for processing (10)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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
Adds a one-line installer and a release Compose file so getting started is one command instead of a clone plus a hand-written
.env.scripts/install.sh— checks Docker and Compose v2, installs into~/opencode-manager(override withOCM_DIR), and prompts for the optional extras (OpenCode config import, repos folder mount, LAN sign-in). Re-running it updates the install.docker-compose.release.yml— runs the publishedghcr.ioimage under the Compose project nameocm. The installer saves it asdocker-compose.yml.docker-compose.ymlin a checkout keeps building from source, sogit pull+./scripts/docker-upgrade.shis unchanged.AUTH_SECRETis generated on first container start and persisted to/app/data/.auth-secret(mode 0600) when unset, so Compose installs need no.env.Safety
The installer refuses to install when the target is a source checkout, or when another OpenCode Manager container is already running. It never overwrites a tracked
docker-compose.ymlor silently swaps the auth secret / volumes.Tests
vitest run test/scripts/— 170 pass, including new installer, entrypoint, and compose-parity teststsc --noEmit,eslint,shellcheckcleanThe website quick start and docs for this flow live in the web repo.
Summary by CodeRabbit