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

Feature/automated docker release #42

Merged
merged 5 commits into from
Feb 8, 2022

Conversation

emre-f
Copy link
Collaborator

@emre-f emre-f commented Jan 26, 2022

Regarding issue #37:
Created a separate workflow file which is only to be triggered when there is a push happening in main (which will only happen when a PR is being merged from develop).

In this workflow, a docker image will be released with the correct tag.

-> Created a separate yaml file only for releases (develop -> main)
-> Renamed yaml files
Correct test tag, instead of tag test
@emre-f emre-f linked an issue Jan 28, 2022 that may be closed by this pull request
Copy link
Member

@jb-adams jb-adams left a comment

Choose a reason for hiding this comment

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

releases.yml looks like it duplicates a lot of steps from tests.yml, like all the unit and docker testing. We want the release step to be dependent on unit and docker tests passing, but not for them to run twice.

Maybe it's best to put everything back into one file? And have a distinct Docker-Release job that needs Docker-Integration-Test to pass.

You could do something like:

jobs:
    ...
    Docker-Release:
        if: # expression to run when there's a merge into main

See the Github Actions docs for jobs and expressions

Copy link
Member

@jb-adams jb-adams left a comment

Choose a reason for hiding this comment

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

Looks good @emre-f , have you tested that the Docker-Release successfully pushes to the docker registry?

@emre-f
Copy link
Collaborator Author

emre-f commented Feb 8, 2022

I just ran the tests without the main condition, and instead of a docker image with the tag test, the one with tag 0.5.7 was updated.

@jb-adams jb-adams merged commit 27c79e1 into develop Feb 8, 2022
@jb-adams jb-adams deleted the feature/automated-docker-release branch February 8, 2022 18:23
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.

Automate docker releases in github actions
2 participants