feat(github): add tag pattern filtering for deployments#3390
Open
AHTOOOXA wants to merge 3 commits intoDokploy:canaryfrom
Open
feat(github): add tag pattern filtering for deployments#3390AHTOOOXA wants to merge 3 commits intoDokploy:canaryfrom
AHTOOOXA wants to merge 3 commits intoDokploy:canaryfrom
Conversation
Add ability to filter which tags trigger deployments using glob patterns. Users can now specify patterns like "v*", "release-*" to selectively deploy. Changes: - Add tagPatterns field to application and compose schemas - Add getGithubTags API endpoint to fetch repository tags - Implement pattern matching in webhook handler using micromatch - Add Tag Patterns multi-select UI with creatable input - Backwards compatible: empty patterns = deploy on any tag 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…d safety improvements - Extract TagPatternsField into a shared component to fix React hooks anti-pattern (useState was being called inside render callback which violates Rules of Hooks) - Remove ~270 lines of duplicate code between application and compose providers - Add tagPatterns field to test fixtures (drop.test.ts, traefik.test.ts) - Add try-catch around micromatch.isMatch() for defensive error handling 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
167fcb5 to
dd9931a
Compare
dd9931a to
aa1ee97
Compare
Author
|
Hey @Siumauricio 👋 Would love to get your eyes on this when you have a moment! Just rebased onto latest canary to resolve the merge conflicts. Everything should be clean now. |
Contributor
|
bump |
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.
Why This Feature?
Problem: Teams using tag-based deployments currently have no control over which tags trigger deployments. Every single tag (test tags, RC tags, feature tags) triggers a deploy - causing unwanted deployments and wasted resources.
Real-world use cases this enables:
v*tags, ignoretest-*ordev-*release-*to production, ignorerc-*candidatesbackend-v*tags for backend service,frontend-v*for frontendprod-*tags, skipstaging-*andhotfix-*Example: A team pushing
v1.0.0,v1.0.1-rc1,test-feature-xtags can now configure patternv[0-9]*to only deploy final releases.Summary
v*,release-*,v[0-9].*to selectively deployChanges
Backend
tagPatternsfield toapplicationandcomposedatabase schemasgetGithubTagsAPI endpoint to fetch repository tags via GitHub APIapiFindGithubTagsvalidation schemasaveGithubProvidermutation to includetagPatternsmicromatchlibraryFrontend
TagPatternsFieldas shared component (follows React hooks best practices)Database Migration
tagPatternscolumn (text array, default empty) to bothapplicationandcomposetablesTests
tagPatternsfield to test fixturesBackwards Compatibility
Existing applications configured to deploy on tags will continue to work unchanged:
tagPatterns(default) = deploys on ANY tag (same as before)Test plan
v*)🤖 Generated with Claude Code