.. code-block:: shell
docker pull simgrid/tuto-s4u
- docker run -it --rm --name simgrid --volume ~/simgrid-tutorial:/src/tutorial simgrid/tuto-s4u bash
+ docker run -it --rm --name simgrid --volume ~/simgrid-tutorial:/source/tutorial simgrid/tuto-s4u bash
This will start a new container with all you need to take this
tutorial, and create a ``simgrid-tutorial`` directory in your home on
-your host machine that will be visible as ``/src/tutorial`` within the
+your host machine that will be visible as ``/source/tutorial`` within the
container. You can then edit the files you want with your favorite
editor in ``~/simgrid-tutorial``, and compile them within the
container to enjoy the provided dependencies.
.. warning::
- Any change to the container out of ``/src/tutorial`` will be lost
+ Any change to the container out of ``/source/tutorial`` will be lost
when you log out of the container, so don't edit the other files!
All needed dependencies are already installed in this container
optional in this tutorial, it is not installed to reduce the image
size.
-The code template is available under ``/src/simgrid-template-s4u`` in
+The code template is available under ``/source/simgrid-template-s4u`` in
the image. You should copy it to your working directory when you first
log in:
.. code-block:: shell
- cp -r /src/simgrid-template-s4u/* /src/tutorial
- cd /src/tutorial
+ cp -r /source/simgrid-template-s4u/* /source/tutorial
+ cd /source/tutorial
Using your Computer Natively
............................
.. code-block:: shell
docker pull simgrid/tuto-smpi
- docker run -it --rm --name simgrid --volume ~/smpi-tutorial:/src/tutorial simgrid/tuto-smpi bash
+ docker run -it --rm --name simgrid --volume ~/smpi-tutorial:/source/tutorial simgrid/tuto-smpi bash
This will start a new container with all you need to take this
tutorial, and create a ``smpi-tutorial`` directory in your home on
-your host machine that will be visible as ``/src/tutorial`` within the
+your host machine that will be visible as ``/source/tutorial`` within the
container. You can then edit the files you want with your favorite
editor in ``~/smpi-tutorial``, and compile them within the
container to enjoy the provided dependencies.
.. warning::
- Any change to the container out of ``/src/tutorial`` will be lost
+ Any change to the container out of ``/source/tutorial`` will be lost
when you log out of the container, so don't edit the other files!
All needed dependencies are already installed in this container
-(SimGrid, a C/C++ compiler, a Fortran compiler, make, pajeng and
-R). Vite being only optional in this tutorial, it is not installed to
-reduce the image size.
+(SimGrid, the C/C++/Fortran compilers, make, pajeng and R). Vite being
+only optional in this tutorial, it is not installed to reduce the
+image size.
-The code template is available under ``/src/simgrid-template-smpi`` in
-the image. You should copy it to your working directory when you first
-log in:
+The container also include the example platform files from the
+previous section as well as the source code of the NAS Parallel
+Benchmarks. These files are available under
+``/source/simgrid-template-smpi`` in the image. You should copy it to
+your working directory when you first log in:
.. code-block:: shell
- cp -r /src/simgrid-template-smpi/* /src/tutorial
- cd /src/tutorial
+ cp -r /source/simgrid-template-smpi/* /source/tutorial
+ cd /source/tutorial
Using your Computer Natively
............................
# - Install SimGrid's dependencies
# - Compile and install SimGrid itself
RUN echo "DOWNLOAD_URL: ${DLURL}" && \
- apt update && apt install -y wget && \
- mkdir /src && cd /src && \
+ apt update && apt upgrade -y && apt install -y wget && \
+ mkdir /source && cd /source && \
wget https://framagit.org/${DLURL} && \
tar xf SimGrid-* && rm SimGrid-*tar.gz && \
cd SimGrid-* && \
# - Clone simgrid-template-s4u, as it is needed by the tutorial
RUN apt install -y pajeng r-base r-cran-ggplot2 r-cran-dplyr cmake g++ git && \
- cd /src && \
+ cd /source && \
git clone --depth=1 https://framagit.org/simgrid/simgrid-template-s4u.git simgrid-template-s4u.git && \
apt autoremove -y && apt clean && apt autoclean
\ No newline at end of file
--- /dev/null
+# Base image
+FROM simgrid/unstable
+
+# - Clone simgrid-template-smpi, as it is needed by the tutorial
+RUN apt update && apt install -y pajeng r-base r-cran-ggplot2 r-cran-dplyr build-essential g++ gfortran git && \
+ cd /source && \
+ git clone --depth=1 https://framagit.org/simgrid/simgrid-template-smpi.git simgrid-template-smpi.git && \
+ apt autoremove -y && apt clean && apt autoclean
\ No newline at end of file
# - Install SimGrid's dependencies
# - Compile and install SimGrid itself. Clean the tree.
# - Remove everything that was installed, and re-install what's needed by the SimGrid libraries before the Gran Final Cleanup
-RUN apt update && \
+RUN apt update && apt -y upgrade && \
apt install -y g++ gcc git valgrind default-jdk gfortran libboost-dev libboost-all-dev cmake dpkg-dev && \
- mkdir /src/ && cd /src && git clone --depth=1 https://framagit.org/simgrid/simgrid.git simgrid.git && \
+ mkdir /source/ && cd /source && git clone --depth=1 https://framagit.org/simgrid/simgrid.git simgrid.git && \
cd simgrid.git && \
cmake -DCMAKE_INSTALL_PREFIX=/usr/ -Denable_documentation=OFF -Denable_java=ON -Denable_smpi=ON -Denable_compile_optimizations=ON . && \
make -j4 install && \
@echo " make stable -> build the latest stable version of SimGrid (with SMPI w/o MC)"
@echo " make unstable -> build the git version of SimGrid (with SMPI, w/o MC)"
@echo " make tuto-s4u -> build all what you need to take the S4U tutorial"
+ @echo " make tuto-smpi -> build all what you need to take the SMPI tutorial"
@echo " make push -> push all images to the cloud"
@echo "All our images are based on debian:testing"
@echo "Also possible: DOCKER_EXTRA=--no-cache make unstable"
$(DOCKER_EXTRA) \
. | tee > build-deps.log
+build-deps-stable:
+ docker build -f Dockerfile.build-deps-stable \
+ -t simgrid/build-deps-stable:latest \
+ -t simgrid/build-deps-stable:$$(date --iso-8601) \
+ $(DOCKER_EXTRA) \
+ . | tee > build-deps-stable.log
+
tuto-s4u:
docker build -f Dockerfile.tuto-s4u \
-t simgrid/tuto-s4u:latest \
-t simgrid/tuto-s4u:$$(date --iso-8601) \
$(DOCKER_EXTRA) \
- . | tee > tuto.log
+ . | tee > tuto-s4u.log
+
+tuto-smpi:
+ docker build -f Dockerfile.tuto-smpi \
+ -t simgrid/tuto-smpi:latest \
+ -t simgrid/tuto-smpi:$$(date --iso-8601) \
+ $(DOCKER_EXTRA) \
+ . | tee > tuto-smpi.log
push:
docker push simgrid/build-deps
docker push simgrid/stable
docker push simgrid/unstable
docker push simgrid/tuto-s4u
+ docker push simgrid/tuto-smpi