-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
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
Improve Docker Tags #390
Improve Docker Tags #390
Conversation
396a64a
to
1564066
Compare
1564066
to
ed1ce37
Compare
docker push $DOCKER_GENERATOR_IMAGE_NAME | ||
echo "Pushed to $DOCKER_GENERATOR_IMAGE_NAME"; | ||
docker push $DOCKER_CODEGEN_CLI_IMAGE_NAME | ||
echo "Pushed to $DOCKER_CODEGEN_CLI_IMAGE_NAME"; |
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.
If docker push $DOCKER_GENERATOR_IMAGE_NAME
fails but docker push $DOCKER_CODEGEN_CLI_IMAGE_NAME
succeeds, is it correct to say that the CI job will still build successfully?
(I think such situation rarely occurs but still want to confirm the behavior in case that happens)
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.
Good question.
Did my modification changed this?
Was this the reason why there was 2 items in the old version?
- if [ $DOCKER_HUB_USERNAME ]; ... => DOCKER_GENERATOR_IMAGE_NAME
- if [ $DOCKER_HUB_USERNAME ]; ... => DOCKER_CODEGEN_CLI_IMAGE_NAME
My idea to bring both together was to reduce copy-paste code, but I can split it back to 2 items.
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.
Was this the reason why there was 2 items in the old version?
I wasn't the one who added it but that could be the reason.
My idea to bring both together was to reduce copy-paste code, but I can split it back to 2 items.
I definitely like your idea and formatting to make the 1-liner bash command more readable.
What about checking the exit status of line 141 before proceeding further?
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.
What about checking the exit status of line 141 before proceeding further?
Good Idea, am not not really an expert in this domain.
From the doc https://docs.travis-ci.com/user/customizing-the-build
We are using the flag: Lines 92 to 94 in ed1ce37
So I think we the case described by @wing328 seems to be covered. |
👌 Merging this into master. Thanks for the enhancement. |
The change introduced by this PR did not work on travisCI. It was reverted with commit d43801a |
* master: (116 commits) 3.1.0 release (OpenAPITools#486) Fix broken link to openapi generator plugin README (OpenAPITools#484) show warning message for nodejs server only (OpenAPITools#481) Add grokify to Go technical committee (OpenAPITools#479) [Slim] Improve codebase decouple (OpenAPITools#438) Ensure typescript samples are up to date (OpenAPITools#444) Update README.md [Golang][client] delete sample output dir before rebuild (OpenAPITools#477) update petstore samples (OpenAPITools#478) Revert "Improve Docker Tags (OpenAPITools#390)" update go client test dependencies (OpenAPITools#468) [Golang][client] fix for schema definition name `file` (OpenAPITools#433) Fix '.travis' file (syntax) make LICENSE GitHub display compatible (OpenAPITools#467) Improve Docker Tags (OpenAPITools#390) [Golang][client] fix file suffix for _test.go (OpenAPITools#449) Remove copy section (OpenAPITools#463) Add link to presentation (OpenAPITools#465) Use postProcessOperationsWithModels(Map, List) (OpenAPITools#431) [C] Adding petstore sample written in C (OpenAPITools#306) ...
This PR improve the way Docker-Tags are made. See the discussion in #364.
In addition to what we have now (
latest
and tags for version), new tags forSNAPSHOT
version are introduced:3.0.x
Tag: contains first3.0.2-SNAPSHOT
and after the3.0.2
release it contains3.0.3-SNAPSHOT
and so on.3.1.x
Tag: contains first3.1.0-SNAPSHOT
and after the3.1.0
release it contains3.1.1-SNAPSHOT
and so on.4.0.x
Tag: contains first4.0.0-SNAPSHOT
and after the4.0.0
release it contains4.0.1-SNAPSHOT
and so on.