-
Notifications
You must be signed in to change notification settings - Fork 0
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
Add GitHub Actions workflow to build and push Docker images #18
base: main
Are you sure you want to change the base?
Conversation
This workflow triggers on commits to the master branch and tag pushes. It builds and pushes Docker images for both release and development versions, supporting multiple architectures.
Added 'build-images' branch to the workflow trigger for push requests.
- name: Build and push development image | ||
if: ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/master'}} | ||
uses: docker/build-push-action@v6 | ||
with: | ||
context: development/dev-image | ||
push: true | ||
platforms: linux/amd64,linux/arm64 | ||
tags: nutsfoundation/nuts-node:dev |
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.
probably no dev image needed. (also wrong tag)
id: docker_meta | ||
uses: docker/metadata-action@v5 | ||
with: | ||
images: nutsfoundation/nuts-node |
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 should not go under nutsfoundation/nuts-node
- name: Login to Docker Hub | ||
if: ${{ github.event_name != 'pull_request' }} | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} |
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.
pushing this to docker would require setting up branch protection and mandatory code reviews etc. Maybe better to wait a bit and just build locally when needed
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.
several references to master
branch should be replaced with main
branch
this also requires strict branch protection and reviews from code owners. |
This workflow triggers on commits to the master branch and tag pushes. It builds and pushes Docker images for both release and development versions, supporting multiple architectures.