Skip to content

Commit

Permalink
Update dockerfiles to ubuntu-20.04 and autoconf
Browse files Browse the repository at this point in the history
The nvidia/cuda:10.2 image disappeared from the hub, so the GPU
versions in master were not buildable anymore.  Also, the two that
build bifrost were not yet using the configure script.

However, the full-build `.gpu` version doesn't quite work because
nvidia-docker seems to provide access to GPU during run phase, but not
during build phase.  Perhaps relevant:
https://stackoverflow.com/questions/59691207/docker-build-with-nvidia-runtime

The `_prereq.gpu` version builds fully and is still helpful.

Also pinging PR #92 which is outdated but relevant.
  • Loading branch information
league committed Jul 20, 2023
1 parent 0bab382 commit a8ddfa9
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 17 deletions.
34 changes: 26 additions & 8 deletions Dockerfile.cpu
Original file line number Diff line number Diff line change
@@ -1,28 +1,46 @@
FROM ledatelescope/bifrost:cpu-base
FROM ubuntu:20.04

MAINTAINER Ben Barsdell <[email protected]>

ARG DEBIAN_FRONTEND=noninteractive

ENV TERM xterm

# Get dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
python-pip \
build-essential \
curl \
git \
pkg-config \
software-properties-common \
python3 \
python3-dev \
python3-pip \
python-is-python3 \
pylint \
doxygen \
exuberant-ctags \
nano \
vim \
&& \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

# Update ctypesgen
RUN pip --no-cache-dir install \
ctypesgen==1.0.2
setuptools \
numpy \
matplotlib \
contextlib2 \
simplejson \
pint \
ctypesgen==1.0.2 \
graphviz

ENV TERM xterm

# Build the library
WORKDIR /bifrost
COPY . .
RUN make clean && \
make -j NOCUDA=1 && \
RUN ./configure --disable-cuda && \
make -j && \
make doc && \
make install

Expand Down
11 changes: 6 additions & 5 deletions Dockerfile.gpu
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM nvidia/cuda:10.2-devel-ubuntu18.04
FROM nvidia/cuda:12.2.0-devel-ubuntu20.04

MAINTAINER Ben Barsdell <[email protected]>

Expand All @@ -11,9 +11,10 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
git \
pkg-config \
software-properties-common \
python \
python-dev \
python-pip \
python3 \
python3-dev \
python3-pip \
python-is-python3 \
pylint \
doxygen \
exuberant-ctags \
Expand All @@ -38,7 +39,7 @@ ENV TERM xterm
# Build the library
WORKDIR /bifrost
COPY . .
RUN make clean && \
RUN ./configure && \
make -j && \
make doc && \
make install
Expand Down
10 changes: 6 additions & 4 deletions Dockerfile_prereq.gpu
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM nvidia/cuda:10.2-devel-ubuntu18.04
FROM nvidia/cuda:12.2.0-devel-ubuntu20.04

MAINTAINER Ben Barsdell <[email protected]>

Expand All @@ -11,9 +11,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
git \
pkg-config \
software-properties-common \
python \
python-dev \
python-pip \
python3 \
python3-dev \
python3-pip \
python-is-python3 \
pylint \
doxygen \
exuberant-ctags \
nano \
Expand Down

0 comments on commit a8ddfa9

Please sign in to comment.