Skip to content

Commit 938d11e

Browse files
update dockerfile
1 parent 8dd693d commit 938d11e

1 file changed

Lines changed: 4 additions & 68 deletions

File tree

Lines changed: 4 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -1,78 +1,14 @@
1-
# Use firedrake vanilla image (default architecture, main branch)
2-
FROM firedrakeproject/firedrake-vanilla-default:latest
1+
# Use your prebuilt Firedrake+PETSc+Zoomy environment
2+
FROM ghcr.io/zoomylab/zoomy_firedrake:latest
33

4-
# Set environment variables
5-
ENV DEBIAN_FRONTEND=noninteractive
6-
ENV TZ=Europe/London
7-
8-
# Install additional build tools and dependencies for PETSc
9-
RUN apt-get update && apt-get install -y \
10-
build-essential \
11-
gfortran \
12-
cmake \
13-
git \
14-
sudo \
15-
libblas-dev \
16-
liblapack-dev \
17-
libboost-dev \
18-
libopenblas-dev \
19-
&& rm -rf /var/lib/apt/lists/*
20-
21-
# Rebuild PETSc with mesh adaptivity frameworks enabled
22-
RUN cd /opt/petsc && \
23-
make clean && rm -rf arch-* && \
24-
./configure \
25-
--download-ptscotch \
26-
--with-make-np=8 \
27-
--download-hwloc \
28-
--download-hdf5 \
29-
--with-hdf5=1 \
30-
--with-hdf5-fortran-bindings=0 \
31-
--download-netlib-lapack \
32-
--with-netlib-lapack-c-bindings \
33-
--download-mumps \
34-
--download-scalapack \
35-
--download-parmetis \
36-
--download-superlu_dist \
37-
--download-pastix \
38-
--download-metis \
39-
--download-mmg \
40-
--download-parmmg \
41-
--download-pragmatic \
42-
--download-eigen \
43-
--download-slepc \
44-
--with-shared-libraries \
45-
PETSC_ARCH=arch-firedrake-default && \
46-
make PETSC_DIR=/opt/petsc PETSC_ARCH=arch-firedrake-default all
47-
48-
# Re-install Python PETSc bindings
49-
RUN pip install --no-cache-dir --force-reinstall \
50-
/opt/petsc/src/binding/petsc4py
51-
52-
# --- Install Python dependencies ---
53-
RUN python3 -m pip install --no-cache-dir \
54-
jupyterlab \
55-
notebook \
56-
ipywidgets \
57-
matplotlib \
58-
pandas
59-
60-
61-
# Clean up
62-
RUN rm -rf /var/lib/apt/lists/*
63-
64-
# Adjust these paths to match your layout on the host
4+
# Copy your local library folder into the image
655
COPY library /tmp/library
666

67-
# Install into the zoomy conda environment
7+
# Install your local packages
688
RUN python -m pip install /tmp/library/zoomy_core && \
699
python -m pip install /tmp/library/zoomy_tests && \
7010
python -m pip install /tmp/library/firedrake_animate && \
7111
python -m pip install /tmp/library/zoomy_firedrake && \
7212
rm -rf /tmp/library
7313

74-
# ------------------------------------------------------------
75-
# Default entrypoint
76-
# ------------------------------------------------------------
7714
CMD ["/bin/bash"]
78-

0 commit comments

Comments
 (0)