This repository was archived by the owner on Oct 14, 2026. It is now read-only.
Repository navigation
tod: template-wide default server URL; users only need ONEDEV_TOKEN - #24
Merged
Merged
Conversation
- Template variable onedev_url -> agent env ONEDEV_DEFAULT_SERVER_URL (own name: no conflict with a user secret). - tod wrapper: server URL = ONEDEV_SERVER_URL, else the tod config file, else the template default. - Smoke test checks the default and that a user value wins. READMEs: only the ONEDEV_TOKEN secret is needed. Image tags: node/php v0.9.0, ops v0.8.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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
Every user uses the same OneDev server, so the URL is now a template default and each user only needs the
ONEDEV_TOKENuser secret.main.tf: variableonedev_url(https://host[:port]or empty) → agent envONEDEV_DEFAULT_SERVER_URL. A separate name, so it never conflicts with a user secret.build/tod-env.sh(the/usr/local/bin/todwrapper), server URL precedence:ONEDEV_SERVER_URL(user secret) → tod config file (read withtod config get server-url, tod's own parser) → template default. Token mapping unchanged.ONEDEV_TOKENsecret (with thecoder secret createcommand);vars.example.yamlhasonedev_urlagain.v0.9.0, php-wordpressv0.9.0, opsv0.8.0.Existing workspaces
Nothing changes until a workspace is updated. After the update: users with an
ONEDEV_SERVER_URLsecret or atod configserver URL keep it (they win over the default); the token handling is unchanged.Checks
node-jsbuild: smoke test passes;just lint,just validatepassRelease
vars.yamlneedsonedev_url(set in the release workspace).🤖 Generated with Claude Code