Once a new Dockerfile has been pushed to this repository check if a workflow yml file already exists for it. If so, go into the actions tab and choose the relevant workflow to run. Select "Run workflow" and the image will be built and pushed to quay.io.
If a workflow yml doesn't exist there are a few steps needed.
Firstly, ensure that an empty repository with the appropriate name is created in quay.io. Then make sure the dockerbuild robot has write permissions to that new repository.
Once that is completed, you can create a new workflow yaml.
Copy an existing workflow yaml i.e. cp push-jcvi.yml push-your_image_name.yml
and then edit the following lines:
- Replace
name: Build jcvi
withname: Build your_image_name
- Replace
IMAGE_NAME: jcvi
withIMAGE_NAME: your_image_name
- Replace
IMAGE_TAG: python-3.10_last-1522
withIMAGE_TAG: your_image_tag
If you want to build containers manually and publish them to quay.io then log into GitPod and do the following:
- Build the container (don't forget the
.
):
docker build -t my-image .
use flag -f
to specifically choose a Dockerfile, else it will assume Dockerfile
- Test the container (use doecker to open the container and run the program/s of interest)
docker run --rm -it my-image bash
or (with directory mounted):
docker run --rm -it --volume $PWD:$PWD my-image bash
<Make sure to exit
the docker container>
- Log in with your quay.io account
docker login -u your-username quay.io
and use your access token as the password.
- Tag the image:
docker tag my-image quay.io/ecoflowucl/my-image
with a tag that is appropriate quay.io/ecoflowucl/my-image:v1.0
and change my-image to an appropriate name, all in lower case.
- Push the image:
docker push quay.io/ecoflowucl/my-image
- Make repo public on Quay.io
Go to settings on the Quay webpage for ecoflow
- Go to Quay.io settings, and allow robot account access to write to repo
- Also you need to create a github action file for this repository.
In .github/workflows
.
Copy an example that exists for your container.
- Go to Github and run the container build actions.
pearrm - requires you buying software (free for academics) so uses local copy that can't be added to repo