Repository navigation
feat: variables redesign with global, site and user scopes (v1.3.0) - #64
Merged
Merged
Conversation
Global variables are admin-only, site variables need an editor with site access, and user variables are private. Values resolve as snippet default, then global, site, device, user and the runtime prompt. Adds a tabbed Variables page with Used-in lists and in-app help, a resolved preview in the snippet editor, GET /api/variables/preview and /api/variables/usage, secrets bound to their row with AAD, scheduled snippets resolving the owner's user values like runbooks, and migration 27 (transactional, idempotent) that rebinds existing secrets and enforces one scope per row.
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.
Variables redesign (v1.3.0)
Scopes: Global (admin-only), Site (editors with site access) and User (private).
Override order: snippet default → global → site → device → user → runtime prompt. Snippets, runbooks and schedules all resolve this way. Scheduled snippets now apply the schedule owner's user values, as scheduled runbooks already did.
What's new
docs/variables.md).GET /api/variables/preview).GET /api/variables/usage.variables:<id>:value). They're decrypted only at run time or in the authorised reveal/edit fetch. Legacy ciphertext is rebound on reveal. Portable backups decrypt and re-bind them.siteIdon rows that also had auserId(they were always treated as user values) and adds a one-scope-per-row CHECK.Compatibility
teamandpersonaland still returnsteam,personalandcanEditTeam.Tests
test/variablesRedesign.test.tscovers resolution order, permissions, masking and AAD binding, preview, Used-in, migration idempotency and rollback.shellcheck -S warning agent/*.shall pass.Includes the v1.3.0 release commit (version, CHANGELOG, RELEASE.md).