Building Docker Images - galacticusorg/galacticus GitHub Wiki
Docker images are typically built and released using GitHub Actions. However, they can also be built locally. This requires a machine with docker installed and requires root access.
To build the Galacticus build environment, follow these steps:
- Enter the
galacticusDockerBuildEnvrepo; -
sudo docker build .- to build the image - keep note of theimageIDoutput at the end of the successful build; -
sudo docker tag <imageI> galacticusorg/buildenv:latest- to assign a tag to the image; -
sudo docker push ghcr.io/galacticusorg/buildenv:latest- to push the new image to GitHub.
To build the Galacticus itself, follow these steps:
- Enter the
galacticusrepo; -
sudo docker build --build-arg tag=latest .- to build the image - keep note of theimageIDoutput at the end of the successful build; -
sudo docker tag <imageI> galacticusorg/galacticus:latest- to assign a tag to the image; -
sudo docker push ghcr.io/galacticusorg/galacticus:latest- to push the new image to GitHub.
Note that the tag argument in the above controls which tagged version of galacticusDockerBuildEnv is used as the base image for this build. If you wanted to build using the v1.0.0 tag of galacticusDockerBuildEnv, for example, you would use:
sudo docker build --build-arg tag=v1.0.0 .