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

Refactor to allow multiple image builds #85

Merged
merged 5 commits into from
Dec 25, 2024

Conversation

faeizmahrus
Copy link
Contributor

Simple refactor to generate multiple image containers using the same GitHub Workflow/Actions.

Containerfiles must be stored in /Containerfiles directory, the name of the ContainerFile for an image must be the same as the image name.

e.g. to generate an image named debian-test-dbn, the relevent ContainerFile should be /Containerfiles/debian-test-dbn
Also added an extra /packages directory for packagelists and other things to be stored inside of.

@faeizmahrus
Copy link
Contributor Author

I still find it kinda hacky, is there anyway to scan the Containerfiles directory for containerfiles and add those as arguments for matrix.containerfile ?

This way the user won't need to manually add the names for their containerfile to the .yml workflow file each time they want to add another distrobox container.

@m2Giles
Copy link
Member

m2Giles commented Dec 24, 2024

This looks fine. I would put a guard on fedora-sample so it's not being pushed. In fact I'm unsure if that sample should even be on here right now.

I do like this extension for those who want to fork this repo.

@castrojo
Copy link
Member

castrojo commented Dec 24, 2024

Yeah I'm not sure we want/need the fedora sample? I think we should just keep the one we have so we don't have to maintain a matrix of boxes like we do for the toolboxes repo.

@faeizmahrus
Copy link
Contributor Author

Yeah I'm not sure we want/need the fedora sample? I think we should just keep the one we have so we don't have to maintain a matrix of boxes like we do for the toolboxes repo.

It was included as an example, for demonstration purposes.

I can comment out the fedora-sample line in build-boxkit.yml file so it doesn't actually build, and add a comment saying -
"Uncommenting this line will also build the fedora-sample image"

I think fedora-sample should be renamed to fedora-example, to further clarify it's purpose.

faeizmahrus and others added 4 commits December 25, 2024 09:35
Add `workflow_dispatch` for manually triggering builds
Remove obselete `--disable-content-trust` argument from Push to GHCR action
Enable `oci:` in buildah action
@faeizmahrus
Copy link
Contributor Author

I did some misc. changes, primarily enabling OCI image generation by setting oci: true in the builder action, and removing the obselete --disable-content-trust argument from Push to GHCR action.

I also added workflow_dispatch: so users can manually trigger builds.

Let me know if any of the changes need to be reverted.

@castrojo castrojo merged commit c9f566d into ublue-os:main Dec 25, 2024
0 of 2 checks passed
@faeizmahrus faeizmahrus deleted the generate-multiple-targets branch December 25, 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