Skip to content

Commit

Permalink
More documentation, add container modifications (#9)
Browse files Browse the repository at this point in the history
Allows to append instructions to the container, used here to install compilers.
  • Loading branch information
matz-e authored Dec 11, 2024
1 parent ac8c01f commit af3cb23
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/spacktainer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ jobs:
# - multiscale-run
- neurodamus-hippocampus
- neurodamus-neocortex
- neurodamus-thalamus
- system-benchmarks
runs-on:
- codebuild-spacktainers-tf-${{ github.run_id }}-${{ github.run_attempt }}
Expand All @@ -94,6 +95,9 @@ jobs:
# Triggers building the 'builder' image, otherwise it is optimized away
COPY --from=builder /etc/debian_version /etc/debian_version
EOF
if [[ -f Dockerfile.epilogue ]]; then
cat Dockerfile.epilogue >> Dockerfile
fi
- name: build ${{ matrix.spacktainer }}
uses: ./.github/actions/build_container
with:
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ This repository aims to be the one-stop shop for all of our container needs.

The only files you should have to edit as an end-user are located in the `container_definitions` folder. There's a subfolder per architecture (currently supported: `amd64` and `arm64`) under which both `spack.yaml` (in subdirectories) and `def` files can live.
* A `spack.yaml` file file defines a Spack container - in it you can define the Spack specs as you would in a Spack environment. If you have specific requirements for dependencies, you can add `spack: packages: ...` keys to define those, again, as in a Spack environment.
* If a `Dockerfile.epilogue` is present in the container directory, it will be appended to
the auto-generated `Dockerfile`. This can be used to, e.g., include compilers in the final
container and perform other fine-tuning.
* A def file defines a singularity container that will be built from an existing container on docker-hub. nexus-storage is already defined for amd64 as an example.

In both cases, the filename will be used as the name of your container. In case of a YAML file, the container version will be derived from the first package in your spec. In case of a def file, the version will be the same as the tag on docker hub.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
RUN apt-get update \
&& apt-get install -y gcc g++ make \
&& rm -rf /var/lib/apt/lists/*
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
RUN apt-get update \
&& apt-get install -y gcc g++ make \
&& rm -rf /var/lib/apt/lists/*
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
RUN apt-get update \
&& apt-get install -y gcc g++ make \
&& rm -rf /var/lib/apt/lists/*
8 changes: 8 additions & 0 deletions container_definitions/amd64/neurodamus-thalamus/spack.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
spack:
specs:
- neurodamus-models model=thalamus +coreneuron+caliper
- py-neurodamus
packages:
all:
providers:
mpi: [mpich]

0 comments on commit af3cb23

Please sign in to comment.