From b645989d7f239ad28e2d602d0ed7af1a577c253f Mon Sep 17 00:00:00 2001 From: Steffen Graber Date: Wed, 17 Jul 2024 08:12:04 +0200 Subject: [PATCH 1/4] Add git to Dockerfile --- src/dev/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/src/dev/Dockerfile b/src/dev/Dockerfile index 10472cd..c302eea 100644 --- a/src/dev/Dockerfile +++ b/src/dev/Dockerfile @@ -21,6 +21,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ curl \ cython3 \ freeglut3-dev \ + git \ gosu \ jq \ less \ From d44106d8cbf32c957616ba856903e47864058fd7 Mon Sep 17 00:00:00 2001 From: Steffen Graber Date: Wed, 17 Jul 2024 08:49:50 +0200 Subject: [PATCH 2/4] Install nestml with fix for nest version (#236) * Merge build and deploy to fix deploy problems * Add nest-server requirements * Fix nest-desktop and compose file * Add v3.7 * Remove test * Add v3.7 to readme * Fix nestml version and add pygsl * Install nestml fix for nest verssion --- src/3.8/Dockerfile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/3.8/Dockerfile b/src/3.8/Dockerfile index a6f038e..d33cd81 100644 --- a/src/3.8/Dockerfile +++ b/src/3.8/Dockerfile @@ -117,9 +117,13 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ python3 -m pip install -r ${SRC_PATH}/nest-simulator-${NEST_VERSION}/requirements.txt && \ python3 -m pip install --upgrade nest-desktop && \ python3 -m pip install --upgrade scipy && \ - python3 -m pip install --upgrade gsl wheel setuptools swig && \ - python3 -m pip install nestml==8.0.0rc1 && \ - python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b1 && \ + python3 -m pip install --upgrade gsl wheel setuptools swig + +RUN python3 -m pip install https://api.github.com/repos/nest/nestml/zipball/pull/1087/head + + # python3 -m pip install nestml==8.0.0rc1 && \ + +RUN python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b1 && \ python3 -m pip install --upgrade pygsl@git+https://github.com/pygsl/pygsl@v2.3.3 COPY entrypoint.sh /usr/local/bin/entrypoint.sh From 6f9e0d2dacda5188ae744b1a234738a59bd9f716 Mon Sep 17 00:00:00 2001 From: Sebastian Spreizer Date: Wed, 17 Jul 2024 13:46:13 +0200 Subject: [PATCH 3/4] Nestml server v1.0 b2 (#237) * Fix not finding files using LD_LIBRARY_PATH * Add port to expose and nestmlmodules path to LD_LIBRARY_PATH * Better solution to add module path to LD_LIBRARY_PATH --- src/3.8/Dockerfile | 4 ++-- src/3.8/entrypoint.sh | 6 +++++- src/dev/Dockerfile | 4 ++-- src/dev/entrypoint.sh | 6 +++++- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/src/3.8/Dockerfile b/src/3.8/Dockerfile index d33cd81..65351c5 100644 --- a/src/3.8/Dockerfile +++ b/src/3.8/Dockerfile @@ -123,7 +123,7 @@ RUN python3 -m pip install https://api.github.com/repos/nest/nestml/zipball/pull # python3 -m pip install nestml==8.0.0rc1 && \ -RUN python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b1 && \ +RUN python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b2 && \ python3 -m pip install --upgrade pygsl@git+https://github.com/pygsl/pygsl@v2.3.3 COPY entrypoint.sh /usr/local/bin/entrypoint.sh @@ -132,5 +132,5 @@ RUN chmod +x /usr/local/bin/entrypoint.sh COPY test-nest.sh /opt/test-nest.sh RUN chmod +x /opt/test-nest.sh -EXPOSE 8080 52425 54286 +EXPOSE 8080 52425 52426 54286 ENTRYPOINT ["/usr/local/bin/entrypoint.sh"] diff --git a/src/3.8/entrypoint.sh b/src/3.8/entrypoint.sh index 5b3df93..b27435e 100644 --- a/src/3.8/entrypoint.sh +++ b/src/3.8/entrypoint.sh @@ -11,11 +11,15 @@ nest --help export MUSIC_ROOT_DIR='$HOME/.cache/music.install' export MUSIC_ROOT=${MUSIC_ROOT_DIR} MUSIC_PATH=${MUSIC_ROOT_DIR} -export LD_LIBRARY_PATH=${MUSIC_PATH}/lib:$LD_LIBRARY_PATH export PATH=${MUSIC_PATH}/bin:$PATH export CPATH=${MUSIC_PATH}/include:$CPATH export PYTHONPATH=${MUSIC_PATH}/lib/python3.8/site-packages:$PYTHONPATH +export NESTML_MODULES_PATH=${NESTML_MODULES_PATH:-/tmp/nestmlmodules} + +# Set LD_LIBRARY_PATH for music and nestml modules +export LD_LIBRARY_PATH=${MUSIC_PATH}/lib:${NESTML_MODULES_PATH}:$LD_LIBRARY_PATH + MODE="${NEST_CONTAINER_MODE:-$1}" if [[ "${MODE}" = 'interactive' ]]; then read -p "Your python script: " name diff --git a/src/dev/Dockerfile b/src/dev/Dockerfile index c302eea..11f35f4 100644 --- a/src/dev/Dockerfile +++ b/src/dev/Dockerfile @@ -140,7 +140,7 @@ RUN python3 -m pip install --upgrade pip && \ python3 -m pip install nest-desktop --pre && \ python3 -m pip uninstall nestml -y && \ python3 -m pip install --upgrade https://github.com/nest/nestml/archive/refs/heads/master.zip && \ - python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b1 + python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b2 RUN python3 -m pip install --force-reinstall --upgrade scipy @@ -150,5 +150,5 @@ RUN chmod +x /usr/local/bin/entrypoint.sh COPY test-nest.sh /opt/test-nest.sh RUN chmod +x /opt/test-nest.sh -EXPOSE 8080 52425 54286 +EXPOSE 8080 52425 52426 54286 ENTRYPOINT ["/usr/local/bin/entrypoint.sh"] diff --git a/src/dev/entrypoint.sh b/src/dev/entrypoint.sh index 5b3df93..b27435e 100644 --- a/src/dev/entrypoint.sh +++ b/src/dev/entrypoint.sh @@ -11,11 +11,15 @@ nest --help export MUSIC_ROOT_DIR='$HOME/.cache/music.install' export MUSIC_ROOT=${MUSIC_ROOT_DIR} MUSIC_PATH=${MUSIC_ROOT_DIR} -export LD_LIBRARY_PATH=${MUSIC_PATH}/lib:$LD_LIBRARY_PATH export PATH=${MUSIC_PATH}/bin:$PATH export CPATH=${MUSIC_PATH}/include:$CPATH export PYTHONPATH=${MUSIC_PATH}/lib/python3.8/site-packages:$PYTHONPATH +export NESTML_MODULES_PATH=${NESTML_MODULES_PATH:-/tmp/nestmlmodules} + +# Set LD_LIBRARY_PATH for music and nestml modules +export LD_LIBRARY_PATH=${MUSIC_PATH}/lib:${NESTML_MODULES_PATH}:$LD_LIBRARY_PATH + MODE="${NEST_CONTAINER_MODE:-$1}" if [[ "${MODE}" = 'interactive' ]]; then read -p "Your python script: " name From 25919b76711da895fcf7705d12108269594875a1 Mon Sep 17 00:00:00 2001 From: Sebastian Spreizer Date: Thu, 18 Jul 2024 06:29:17 +0200 Subject: [PATCH 4/4] Bump to nestml-server v1.0-b3 (#238) --- src/3.8/Dockerfile | 2 +- src/dev/Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/3.8/Dockerfile b/src/3.8/Dockerfile index 65351c5..f026da2 100644 --- a/src/3.8/Dockerfile +++ b/src/3.8/Dockerfile @@ -123,7 +123,7 @@ RUN python3 -m pip install https://api.github.com/repos/nest/nestml/zipball/pull # python3 -m pip install nestml==8.0.0rc1 && \ -RUN python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b2 && \ +RUN python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b3 && \ python3 -m pip install --upgrade pygsl@git+https://github.com/pygsl/pygsl@v2.3.3 COPY entrypoint.sh /usr/local/bin/entrypoint.sh diff --git a/src/dev/Dockerfile b/src/dev/Dockerfile index 11f35f4..763f332 100644 --- a/src/dev/Dockerfile +++ b/src/dev/Dockerfile @@ -140,7 +140,7 @@ RUN python3 -m pip install --upgrade pip && \ python3 -m pip install nest-desktop --pre && \ python3 -m pip uninstall nestml -y && \ python3 -m pip install --upgrade https://github.com/nest/nestml/archive/refs/heads/master.zip && \ - python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b2 + python3 -m pip install nestml-server@git+https://github.com/babsey/nestml-server@v1.0-b3 RUN python3 -m pip install --force-reinstall --upgrade scipy