Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,3 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Install dependencies 📦
run: |
pip install -r requirements.txt
pip freeze

# - name: Run tests
# run: pytest -m "${{ inputs.integration && 'integration' || 'not integration' }}" --target ${{inputs.target}}
# env: ${{ fromJSON(inputs.images) }}
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ Meanwhile, I cumulated a lot of experience on how to build aiida/aiidalab images
Compiling codes within computational materials community is not always trivial. One of the main goals of Quantum Mobile is bring pre-installed tools/codes to users.
Historically, we had switch from using ansible to store the compiling recipe to using conda.
The efforts are enssential for the Quantum Mobile itself but hard to find motivation for the community.
In a long time, I use the `containers4hpc/quantum-espresso` image for multiple different purposes such as for testing my aiida plugin with setting as containerized code.
In a long time, I use the `cnts4sci/quantum-espresso` image for multiple different purposes such as for testing my aiida plugin with setting as containerized code.
It potentially can fit a bigger picture.
Compiling need only happened once in the image repo of the code. The binary can be copy from layer into the final image of Quantum Container.

TODO

- [ ] pre-configured AiiDA in full-stack
- [x] pre-configured AiiDA in full-stack
- [x] developers sugar tools.
- [ ] OPENMPI into base and fix the version range to compatible with `build-machine`
- [ ] use /dev/shm ? check.
Expand All @@ -41,7 +41,7 @@ TODO
- [ ] commandline wrapper to start container with designed parameters such as resolution of vnc server.
- [ ] Docker desktop for windows, test and documentation.
- [ ] At the moment, we copy binaries of every codes to `/usr/local/bin`, there might be conflication on names.
- [ ] Change org name containers4hpc -> containers4sci or cnts4sci or containers4science
- [x] Change org name containers4hpc -> containers4sci or cnts4sci (I choose this) or containers4science
- [ ] Docker test using `testcontainers-rc`.
- [x] gracefully shutdown the vncserver, 1. avoid to show the error message, 2. handle save and clean up of vnc session.
- [ ] instructions as a icon that start the browser page to the tutorial.
Expand All @@ -51,7 +51,7 @@ TODO
### How to run

```bash
docker run -d -p 6080:6080 ghcr.io/containers4hpc/qc-base
docker run -d -p 6080:6080 ghcr.io/cnts4sci/qc-base
```

In your browser open http://localhost:6080, click the connect button and input the password `moritz`. You are ready to use the Linux system.
Expand Down
5 changes: 4 additions & 1 deletion build.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
{
"variable": {
"QUANTUM_ESPRESSO_IMAGE": {
"default": "ghcr.io/containers4hpc/quantum-espresso:v2024.1001"
"default": "ghcr.io/cnts4sci/quantum-espresso:v2024.1001"
},
"ATOMPAW_IMAGE": {
"default": "ghcr.io/pspgen/atompaw:atompaw-4.2.0.3"
},
"ONCVPSP_IMAGE": {
"default": "ghcr.io/pspgen/oncvpsp:oncvpsp-4.0.1"
},
"AIIDA_CORE_VERSION": {
"default": "2.5.2"
}
}
}
17 changes: 15 additions & 2 deletions docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ variable "VERSION" {
}

variable "ORGANIZATION" {
default = "containers4hpc"
default = "cnts4sci"
}

variable "REGISTRY" {
Expand All @@ -15,7 +15,7 @@ variable "PLATFORMS" {
}

variable "TARGETS" {
default = ["qc-base", "qc-full-stack"]
default = ["qc-base", "qc-full-stack", "qc-aiida"]
}

# TAGS for softwares
Expand Down Expand Up @@ -45,6 +45,19 @@ target "qc-base" {
}
}

target "qc-aiida" {
tags = tags("qc-aiida")
context = "qc-aiida"
contexts = {
runtime-base-image = "target:qc-base"
python-base-image = "docker-image://ghcr.io/cnts4sci/python:edge"
}
platforms = "${PLATFORMS}"
args = {
AIIDA_CORE_VERSION = "${AIIDA_CORE_VERSION}"
}
}

target "qc-full-stack" {
tags = tags("qc-full-stack")
context = "qc-full-stack"
Expand Down
55 changes: 55 additions & 0 deletions qc-aiida/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# syntax=docker/dockerfile:1

ARG AIIDA_CORE_VERSION

FROM python-base-image as python-carrier


# This is not needed since qc-base use SYSTEM_USER but better to set
# to emphasis it.
USER ${SYSTEM_USER}

# set up your python path
ENV PATH=/opt/python/bin:${PATH}
ENV LD_LIBRARY_PATH=/opt/python/lib:${LD_LIBRARY_PATH}
ENV C_INCLUDE_PATH=/opt/python/include:${C_INCLUDE_PATH}

# Create a venv named `aiida-runtime` in home
# Install aiida-core and other plugins (???) to the venv
RUN python -m venv ${HOME}/venv/aiida-runtime && \
source ${HOME}/venv/aiida-runtime/bin/activate && \
python -m pip install aiida-core==${AIIDA_CORE_VERSION}

# Create workdir_aiida under ~ and init the profile.
RUN mkdir -p ${HOME}/workdir_aiida && \
verdi setup --non-interactive --config default-profile.yaml

# FROM runtime-base-image
#
# USER root
# # To do this I need RMQ and Sqlite (include in python already)
# # Install erlang and RMQ
# # TODO: simplify me
# WORKDIR /opt
#
# RUN apt-get update --yes && \
# apt-get install --yes --no-install-recommends \
# erlang && \
# apt-get clean && rm -rf /var/lib/apt/lists/* && \
# # Install rabbitmq.
# wget -c -O rmq.tar.xz --no-check-certificate https://github.com/rabbitmq/rabbitmq-server/releases/download/v${RMQ_VERSION}/rabbitmq-server-generic-unix-${RMQ_VERSION}.tar.xz && \
# mkdir rmq && \
# tar xf rmq.tar.xz -C rmq --strip-components=1 && \
# rm rmq.tar.xz
#
# COPY --from=aiida-build-image /opt/python /opt/python
# COPY --from=aiida-build-image ${HOME}/venv/aiida-runtime ${HOME}/ven/aiida-runtime
# COPY --from=aiida-build-image ${HOME}/workdir_aiida ${HOME}/workdir_aiida
#
# # set up python path
# ENV PATH=${HOME}/venv/aiida-runtime/bin:${PATH}
# ENV LD_LIBRARY_PATH=${HOME}/venv/aiida-runtime/lib:${LD_LIBRARY_PATH}
# ENV C_INCLUDE_PATH=${HOME}/venv/aiida-runtime/include:${C_INCLUDE_PATH}
#
# # set up rmq path
# ENV PATH=/opt/rmq/sbin:${PATH}
1 change: 1 addition & 0 deletions qc-full-stack/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
# - bigdfd
# - DFTK
# - siesta
# - gpaw: -> https://hub.docker.com/r/marcindulak/gpaw-openmpi

# ARG need to put all infront of multi-stage FROM
ARG QUANTUM_ESPRESSO_IMAGE
Expand Down