Closed EvanCarroll closed 3 years ago
If your use case is satisfied by this action, you can use this action to build image and push-to-registry action to push to Github Container Registry (or registry of your choice). With this action you can also build image without dockerfile. Check this.
But, if you still want to build image typically using shell you can do something like this in your workflow:
- name: Test Build
run: |
#!/bin/sh
ctr=$(buildah from alpine:3)
buildah commit "$ctr" my-alpine-image
As Github Linux runners comes with buildah pre-installed https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-README.md#installed-software
Is this what you wanted to ask? or something else?
closing pending any further comments
Question
https://devops.stackexchange.com/questions/13524/how-can-i-use-a-buildah-script-for-image-generation-using-github-actions
Buildah scripts typically use shell. You can see an example of a script here,
Let's say I have such a shell script that produces an image "myAlpineImage". How can I use GitHub CI to automate the creation of this image, and preferably uploading it to GitHub Container Registry?