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

Fix caching directories to match with newer Dockerfile, add workflow #22

Merged
merged 8 commits into from
Feb 15, 2024

Conversation

burmanm
Copy link
Collaborator

@burmanm burmanm commented Jan 29, 2024

workflow_dispatch added to create a docker build with cached files for airgap installs

Fixes #23
Fixes #24

@burmanm burmanm marked this pull request as ready for review January 29, 2024 21:51
Copy link
Contributor

@adejanovski adejanovski left a comment

Choose a reason for hiding this comment

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

A few questions there, but no blocker.
Please take the time to answer the security related ones before merging.


on:
push:
tags:
- 'v*.*.*'
workflow_dispatch:
# Allow to rerun this for a tag to get updated UBI-images

jobs:
release_cass_operator:
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggestion: Shouldn't we rename this job like you did for the workflow? something such as release_k8ssandra_client maybe?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah, I can fix that name.

if: ${{ !env.ACT }}
uses: docker/setup-qemu-action@v2
- name: Login to DockerHub
if: ${{ !env.ACT }}
Copy link
Contributor

Choose a reason for hiding this comment

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

Thought: interesting, that's how you create specific behaviors for ACT then 👍
Do you want to keep those for future needs in terms of local development?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It would be nice to keep them, it helps to not require each time to have local changes to test something.

create_the_image:
runs-on: ubuntu-latest
env:
GH_TOKEN: ${{ secrets[format('{0}', inputs.tokenSecret)] }}
Copy link
Contributor

Choose a reason for hiding this comment

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

Question: How safe is it to pass this PAT as a string input for this workflow dispatch? Any possibility that the token could leak in the logs?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We don't pass PAT itself to this workflow. We pass a secret name (which this repository has) that has the PAT. Passing PAT itself through workflow_dispatch wouldn't be safe.

@adejanovski
Copy link
Contributor

@burmanm, can you follow up on this? Thanks!

@burmanm burmanm merged commit 41178b9 into k8ssandra:main Feb 15, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants