-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
feat(ecr-assets): expose property imageTag separately from imageUri in ECR assets #21582
Changes from 6 commits
38e73bc
b906fa0
bda59c0
c61d9f2
878b81a
98f96bd
5ecad0d
6cbe3d5
05640f2
bd49e16
5811a19
08e6e7a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -319,4 +319,10 @@ export interface DockerImageAssetLocation { | |||||
* The name of the ECR repository. | ||||||
*/ | ||||||
readonly repositoryName: string; | ||||||
|
||||||
/** | ||||||
* The tag of the image in Amazon ECR. | ||||||
* @default ${dockerTagPrefix}${asset.sourceHash} | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
does this work? It seems weird to not have the backticks on the default There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I did not want the docs to actually parse the values, just show that it is the two concatenated. There may be a better way to represent that. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This needs to be documentation that makes sense for other languages. This convention is specific to TypeScript/JavaScript and may not translate properly. This should be descriptive of what the default will be, not a code snippet. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I changed it to I can be more descriptive, say "dockerTagPrefix concatenated with the sourceHash of the asset", but I think the + conveys string concatenation agnostically |
||||||
*/ | ||||||
readonly imageTag?: string; | ||||||
} |
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.
I'm not sure about the name
synthesized
Tag. What aboutimageTag
instead?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.
I chose
synthesizedTag
to make it clear that this will differ fromassetHash
when a synthesizer adds adockerTagPrefix
. I was also worried that a user would seeimageUri
andimageTag
and think that they are distinct instead of knowingimageUri
includes the tag (I have done this in my project).If you feel those concerns are relatively minor, I am fine with
imageTag
.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.
Is this a public facing field or something that we use in our internal logic?
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 is a public facing field. I changed it to
imageTag
everywhere.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.
imageTag
is good. The relationship between uri and tag is docker domain knowledge. I don't think it would be a good idea to abstract that away.