From c644ba914c4026a44c06ab6e3f323508adb34177 Mon Sep 17 00:00:00 2001 From: alexPatrie Date: Sun, 7 Jan 2024 17:17:34 -0500 Subject: [PATCH] updates to dockerfile --- Dockerfile | 32 ++++++++++++++++++++++---------- README.md | 2 +- scripts/run-docker.sh | 5 ++++- 3 files changed, 27 insertions(+), 12 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7933b0a02..433cf95d2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # TODO: Make this work for Smoldyn to be platform-agnostic -FROM python:3.10-bullseye +FROM ubuntu:22.04 # Implement the next two lines for use in Cloud # RUN useradd -m simuser @@ -12,19 +12,31 @@ WORKDIR /app COPY . /app RUN apt-get update && apt-get install -y \ - build-essential \ wget \ - libgl1-mesa-dev \ - libglu1-mesa-dev \ + # Add any other dependencies required by smoldyn && rm -rf /var/lib/apt/lists/* -RUN echo 'deb http://download.opensuse.org/repositories/home:/dilawar/Debian_11/ /' | tee /etc/apt/sources.list.d/home:dilawar.list -RUN curl -fsSL https://download.opensuse.org/repositories/home:dilawar/Debian_11/Release.key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/home_dilawar.gpg > /dev/null -RUN apt update -RUN apt install smoldyn +# Download the smoldyn .deb package +RUN wget https://download.opensuse.org/repositories/home:/dilawar/xUbuntu_22.04/amd64/smoldyn_2.64.4-1+2.1_amd64.deb + +# Install the downloaded package +RUN dpkg -i smoldyn_2.64.4-1+2.1_amd64.deb + + +# RUN apt-get update && apt-get install -y \ +# build-essential \ +# wget \ +# libgl1-mesa-dev \ +# libglu1-mesa-dev \ +# # && rm -rf /var/lib/apt/lists/* + +# RUN echo 'deb http://download.opensuse.org/repositories/home:/dilawar/Debian_11/ /' | tee /etc/apt/sources.list.d/home:dilawar.list +# RUN curl -fsSL https://download.opensuse.org/repositories/home:dilawar/Debian_11/Release.key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/home_dilawar.gpg > /dev/null +# RUN apt update +# RUN apt install smoldyn RUN pip install --upgrade pip \ - && pip install . ipython - # && pytest + && pip install ipython \ + && pip install . CMD ["ipython3"] diff --git a/README.md b/README.md index 3b3be4540..93a3047a7 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ install the dependencies required for your use. Most of the direct UI content for this tooling will be in the form of a jupyter notebook. -### Using `core_processes.smoldyn_process.SmoldynProcess()`: +### Using `biosimulator_processes.smoldyn_process.SmoldynProcess()`: #### PLEASE NOTE: Due to the multi-lingual nature of Smoldyn, which is primarily diff --git a/scripts/run-docker.sh b/scripts/run-docker.sh index f0dc7620a..624f92221 100755 --- a/scripts/run-docker.sh +++ b/scripts/run-docker.sh @@ -1,2 +1,5 @@ #!/bin/bash -docker build -t biosimulator-processes . && docker run -it biosimulator-processes +docker buildx create --name biosimbuilder --use +docker buildx inspect --bootstrap +docker buildx build --platform linux/amd64 -t biosimulator-processes . \ + && docker run biosimulator-processes