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

chore(ci): build images with dockerfile instead of ko #332

Merged
merged 2 commits into from
Jul 23, 2024

Conversation

mikhailswift
Copy link
Member

Our Dockerfile includes our migrations and Atlas to execute those migrations. However, the public image we are pushing is built with Ko and excludes these files/tools. This commit switches gorelease to build the image with the included Dockerfile.

What this PR does / why we need it

Description

Which issue(s) this PR fixes (optional)

(optional, using fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when the PR gets merged)*

Fixes #

Acceptance Criteria Met

  • Docs changes if needed
  • Testing changes if needed
  • All workflow checks passing (automatically enforced)
  • All review conversations resolved (automatically enforced)
  • DCO Sign-off

Special notes for your reviewer:

kairoaraujo
kairoaraujo previously approved these changes Jul 23, 2024
@kairoaraujo
Copy link
Collaborator

@mikhailswift
I'm trying to understand this error here https://github.com/in-toto/archivista/actions/runs/10045026639/job/27762025317?pr=332
I think is because the previous error (I retriggered)

@colek42
Copy link
Member

colek42 commented Jul 23, 2024

We can use this feature with KO. https://github.com/ko-build/ko/blob/main/docs/features/static-assets.md

Since we are using KO for dev previews in JUDGE, and KO does not require Docker I think we should try this.

@mikhailswift
Copy link
Member Author

mikhailswift commented Jul 23, 2024

@mikhailswift I'm trying to understand this error here https://github.com/in-toto/archivista/actions/runs/10045026639/job/27762025317?pr=332 I think is because the previous error (I retriggered)

This error is happening because the witness-run-action installs witness to the current working directory, which overwrites archivista's README.md and LICENSE file with the one packaged in witness.tar.gz, causing a dirty git tree. I have a PR out for the witness-run-action to add an option to install witness to a user defined directory.

testifysec/witness-run-action#13

Our Dockerfile includes our migrations and Atlas to execute those
migrations. However, the public image we are pushing is built with Ko
and excludes these files/tools. This commit switches gorelease to build
the image with the included Dockerfile.

Signed-off-by: Mikhail Swift <[email protected]>
This updates the witness-run-action, and installs witness to a directory
outside of the current source directory. This keeps our source git tree
clean.

Signed-off-by: Mikhail Swift <[email protected]>
@kairoaraujo kairoaraujo merged commit d7913a6 into main Jul 23, 2024
18 checks passed
@kairoaraujo kairoaraujo deleted the chore/use-dockerfile branch July 23, 2024 18:00
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