Skip to content

Commit 5b60ecd

Browse files
committed
Add pip installation step.
Some package requirements cannot easily be satisfied by spack, therefore some packages must be installed via pip. Also make the filenames more in line with the purpose of this Dockerfile, namely to provide and end-to-end test of the ChimbukoVisualizationII (cv2) package.
1 parent 9be31e4 commit 5b60ecd

File tree

6 files changed

+33
-24
lines changed

6 files changed

+33
-24
lines changed

docker/ubuntu18.04/openmpi4.0.4/all_spack/Dockerfile.spack_dev_ddb renamed to docker/ubuntu18.04/openmpi4.0.4/all_spack/Dockerfile.cv2

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,11 @@ RUN apt-get update && apt-get install -y emacs-nox gdb tmux vim
44

55
WORKDIR /src
66

7-
RUN echo 0.1.2
8-
97
RUN git clone https://github.com/CODARcode/PerformanceAnalysis.git \
108
--branch ckelly_develop_ddb \
119
&& git -C PerformanceAnalysis checkout ckelly_develop_ddb \
1210
&& cp -r PerformanceAnalysis/spack/repo/chimbuko /sds/ \
13-
&& cp -r PerformanceAnalysis/benchmark_suite . \
14-
&& rm -rf PerformanceAnalysis
11+
&& cp -r PerformanceAnalysis/benchmark_suite .
1512

1613
ENV TAU_OPTIONS="-optShared -optRevert -optVerbose -optCompInst"
1714

@@ -37,15 +34,30 @@ RUN source /spack/spack/share/spack/setup-env.sh \
3734
&& spack gc -y \
3835
&& spack clean -a
3936

37+
RUN echo 0.1.9
38+
# Save build time while working on non-spack dependencies
39+
RUN git config --global user.email "dblair@bnl.gov" \
40+
&& git config --global user.name "Dakota Blair"
41+
RUN git -C /src/PerformanceAnalysis pull --strategy-option=theirs
42+
4043
COPY docker/ubuntu18.04/openmpi4.0.4/all_spack/chimbuko_config.sh \
4144
/bld/benchmark_suite/func_multimodal/
4245

43-
COPY scripts/docker/spack_dev_ddb.sh /build.spack.sh
46+
COPY scripts/docker/cv2/build.sh /build.spack.sh
4447
RUN /build.spack.sh
4548

46-
COPY scripts/docker/spack_dev_ddb.rcfile.sh /rcfile.sh
49+
COPY scripts/docker/cv2/pip.sh /build.pip.sh
50+
RUN /build.pip.sh
51+
52+
COPY scripts/docker/cv2/rcfile.sh /rcfile.sh
4753

4854
# ENTRYPOINT ["/bin/bash"] # see Dockerfile.spack_env
4955

50-
CMD ["--rcfile", "/rcfile.sh"]
56+
CMD [ \
57+
"--rcfile", \
58+
"/rcfile.sh", \
59+
"-i", \
60+
"-c", \
61+
"/bld/benchmark_suite/func_multimodal/run.sh" \
62+
]
5163

docker/ubuntu18.04/openmpi4.0.4/all_spack/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Dockerfiles
22

3-
## `Dockerfile.spack_dev_ddb`
3+
## `Dockerfile.cv2`
44

55
This Dockerfile defines an image which can be used to validate the visualization
66
package upgrades. The build will clone the `chimbuko-visualization2` (CV2) repository
@@ -17,8 +17,8 @@ test changes to CV2:
1717

1818
```sh
1919
docker build \
20-
-f docker/ubuntu18.04/openmpi4.0.4/all_spack/Dockerfile.spack_dev_ddb \
21-
-t chimbuko/chimbuko-spack-dev-ddb:ubuntu18.04 \
20+
-f docker/ubuntu18.04/openmpi4.0.4/all_spack/Dockerfile.cv2 \
21+
-t chimbuko/chimbuko-cv2:ubuntu18.04 \
2222
.
2323
```
2424

@@ -28,7 +28,7 @@ docker build \
2828
docker run --rm -it --cap-add=SYS_PTRACE --security-opt seccomp=unconfined \
2929
-p $HOST_PORT:5002 \
3030
-v $(pwd):$(pwd) \
31-
-name ddb-csd \
31+
-name test-cv2 \
3232
chimbuko/chimbuko-spack-dev:ubuntu18.04
3333
```
3434

scripts/docker/spack_dev_ddb.sh renamed to scripts/docker/cv2/build.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,3 @@ spack env activate .
88
spack develop chimbuko-visualization2 @git.dependency_upgrades=dev
99
spack concretize -f
1010
spack install
11-
cd /opt/spack-environment/chimbuko-visualization2
12-
# git checkout dependency_upgrades
13-
# spack install

scripts/docker/cv2/pip.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash
2+
3+
set -eux
4+
5+
source /spack/spack/share/spack/setup-env.sh
6+
cd /opt/spack-environment/
7+
spack env activate .
8+
cd /opt/spack-environment/chimbuko-visualization2/
9+
pip3 install -r requirements.txt

scripts/docker/spack_dev_ddb.rcfile.sh renamed to scripts/docker/cv2/rcfile.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ cd /opt/spack-environment/
77
spack env activate .
88
export CHIMBUKO_VIZ_ROOT=$(spack location -i chimbuko-visualization2)
99
cd /bld/benchmark_suite/func_multimodal
10-
# ./run.sh
10+
set +ex

spack/repo/chimbuko/packages/chimbuko-visualization2/package.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,19 @@ class ChimbukoVisualization2(Package):
1515
depends_on('python@3.8')
1616
depends_on('py-mochi-sonata', type=('build', 'run'))
1717
depends_on('py-celery@5.2.2:', type=('build', 'run'))
18-
# depends_on('py-certifi@2024.7.4:2024.7', type=('build', 'run'))
1918
depends_on('py-certifi', type=('build', 'run'))
20-
# depends_on('py-dnspython@2.6.1:2.6', type=('build', 'run'))
2119
depends_on('py-dnspython', type=('build', 'run'))
22-
# depends_on('py-eventlet@0.35.2:0.35', type=('build', 'run'))
2320
depends_on('py-eventlet', type=('build', 'run'))
24-
# depends_on('py-flask-script@=2.0.6', type=('build', 'run'))
2521
depends_on('py-flask-script', type=('build', 'run'))
2622
depends_on('py-flask-socketio@2.9.6:2.9', type=('build', 'run'))
2723
depends_on('py-flask-sqlalchemy@2.5.1:2.5', type=('build', 'run'))
2824
depends_on('py-flask@=1.1.2', type=('build', 'run'))
2925
depends_on('py-gevent@23.7.0:', type=('build', 'run'))
30-
# depends_on('py-idna@3.7:', type=('build', 'run'))
3126
depends_on('py-idna', type=('build', 'run'))
32-
# depends_on('py-jinja2@3.0.3:3.0', type=('build', 'run'))
3327
depends_on('py-jinja2', type=('build', 'run'))
34-
# depends_on('py-redis@4.5.4:4.5', type=('build', 'run'))
35-
# depends_on('py-requests@2.32.3:', type=('build','run'))
3628
depends_on('py-requests', type=('build','run'))
3729
depends_on('py-runstats@1.8.0:', type=('build', 'run'))
3830
depends_on('py-sqlalchemy@1.4.45:1.4', type=('build', 'run'))
39-
# depends_on('py-urllib3@1.26.19:1.26', type=('build', 'run'))
4031
depends_on('py-werkzeug@0.16.0:', type=('build', 'run'))
4132
depends_on('redis', type='run')
4233
depends_on('curl', type='run')

0 commit comments

Comments
 (0)