Skip to content
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

ci: Change to login and push only when push is needed #16

Merged
merged 2 commits into from
Dec 7, 2024

Conversation

abetomo
Copy link
Contributor

@abetomo abetomo commented Dec 6, 2024

No description provided.

@abetomo
Copy link
Contributor Author

abetomo commented Dec 6, 2024

Failure of CI is resolved by #15.

if [ "${GITHUB_EVENT_NAME}" = "push" ]; then
need_push="yes"
if [ "${GITHUB_REF_TYPE}" = "tag" ] && [ "${version}" != "${GITHUB_REF_NAME}" ]; then
need_push="no"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"${GITHUB_REF_TYPE}" = "tag"の時はneed_push="yes"ではないでしょうか?

"${GITHUB_REF_TYPE}" = "tag"が成立するのは、tagpushした場合だと思うのですが、tagpushした時は、
DockerイメージもDocker Hub( https://hub.docker.com/r/groonga/groonga )へプッシュされてほしいと思うので。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mroonga/docker から頂戴してきたやつでした。
https://github.com/mroonga/docker/blob/edbf49485c774b817e73c0214b55cbeb040f534d/.github/workflows/build.yml#L26-L38

mroonga/docker の場合はtagプッシュがあっても、タグの種類でDockerイメージをプッシュしたくないときがあったので付けていた条件です。

が、こちらでは不要なので削除しました。

@kou kou merged commit 306ed49 into groonga:main Dec 7, 2024
1 of 2 checks passed
@abetomo abetomo deleted the update-ci-settings branch December 8, 2024 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants