-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dependencies without tags #893
Merged
Merged
Conversation
This file contains 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
…an object containing a tag key
… tags when they arent used
…-dependency-without-tag
TylerAldrich
commented
Apr 17, 2023
Comment on lines
+26
to
+27
} else if (typeof arg === 'object' && 'type' in arg && 'pattern' in arg) { | ||
anyOf.push(arg); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change was needed to specifically support this -
AnyOf({
type: 'string',
pattern: Slugs.ComponentTagValidator.source,
}, DependencySpec)
Currently you can only AnyOf
any string/object/etc, but not a string with a specific pattern, which this now fixes
tjhiggins
requested changes
Apr 18, 2023
…rything to DependencySpec so no string handling is needed Update tests to validate dependency string tags are converted to objects
tjhiggins
requested changes
Apr 18, 2023
…Config object, add tests to validate that works properly, and undo changes that modify the spec so that all dependencies are DependencySpec This reverts commit db66b8f.
github-actions bot
pushed a commit
that referenced
this pull request
Jun 5, 2023
# [1.41.0-rc.1](v1.40.0...v1.41.0-rc.1) (2023-06-05) ### Bug Fixes * **base:** Make sure telemetry does not interfere with CLI ([#913](#913)) ([b92cc8e](b92cc8e)) * **ports:** Use a list of restricted ports instead of allowing ports ([121d0b8](121d0b8)) * **warning:** Add a warning for livenessprobe to let users know that path and port will be deprecated soon ([8bb5dc4](8bb5dc4)) ### Features * **environment:** Add --flag=zero-trust to env:create ([#906](#906)) ([f3ef7b9](f3ef7b9)) * **spec:** Dependencies without tags ([#893](#893)) ([015a3a9](015a3a9))
github-actions bot
pushed a commit
that referenced
this pull request
Jun 5, 2023
# [1.41.0](v1.40.0...v1.41.0) (2023-06-05) ### Bug Fixes * **base:** Make sure telemetry does not interfere with CLI ([#913](#913)) ([b92cc8e](b92cc8e)) * **ports:** Use a list of restricted ports instead of allowing ports ([121d0b8](121d0b8)) * **warning:** Add a warning for livenessprobe to let users know that path and port will be deprecated soon ([8bb5dc4](8bb5dc4)) ### Features * **environment:** Add --flag=zero-trust to env:create ([#906](#906)) ([f3ef7b9](f3ef7b9)) * **spec:** Dependencies without tags ([#893](#893)) ([015a3a9](015a3a9))
🎉 This PR is included in version 1.41.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Related API PR that updates dependency tag resolution to support the various cases where a tag isn't specified and the component does/doesn't exist: https://gitlab.com/architect-io/hub-api/-/merge_requests/763
When a tag is specified, no functionality is changed and the current rules still apply - that is, whatever is currently deployed in the environment is used unless a component is specified in the
architect deploy
command. E.g., ifdependency:tag1
is deployed in an environment, andarchitect deploy component:latest dependency:latest
is run,dependency:latest
will be deployed and replace thedependency:tag1
component. Ifarchitect deploy component:latest
is run, thedependency
component won't get replaced even if the tag in thearchitect.yml
is changed.When no tag is specified, similar rules apply - the only addition is that
latest
is the assumed tag. So, by default,dependency:latest
will be deployed into an environment if it's not specified via the command orarchitect.yml
and thedependency
component doesn't currently exist in the environment.The primary change in the CLI is the spec for dependencies now supports an object value as well as a string. So instead of this:
you can write:
The following is also valid:
The
DependencySpec
object was implemented as a class with an optional deprecatedtag
argument - a completely empty class was causing a lot of issues so I opted to do this instead and defer the issues with an object that must be empty 😬.