Skip to content

Instantly share code, notes, and snippets.

@gorenje
Last active February 18, 2021 15:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gorenje/1799777e28bd68c473ac83df3f0e157a to your computer and use it in GitHub Desktop.
Save gorenje/1799777e28bd68c473ac83df3f0e157a to your computer and use it in GitHub Desktop.
Running Jupyter with SysML in a Docker container
# Using
Copy the Dockerfile to a directory and in that directory do
prompt> docker build -t sysml .
Once the image has built, run it using:
prompt> docker run -p 8888:8888 -t sysml:latest
Then use your favourite browser to visit http://127.0.0.1:8888
You should then be in SysML Jupyter.
FROM openjdk:17-slim
RUN apt-get --quiet --yes update && apt-get install -yqq \
emacs \
wget
WORKDIR /root
##
## Miniconda installation page:
## https://docs.conda.io/en/latest/miniconda.html#linux-installers
##
RUN wget -q https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
##
## SysML page: https://github.com/Systems-Modeling/SysML-v2-Release
##
RUN wget -q https://github.com/Systems-Modeling/SysML-v2-Release/archive/2021-01.tar.gz
RUN chmod 755 /root/Miniconda3-latest-Linux-x86_64.sh
RUN mkdir /usr/conda
RUN /root/Miniconda3-latest-Linux-x86_64.sh -f -b -p /usr/conda
RUN /usr/conda/condabin/conda init
RUN tar xzf 2021-01.tar.gz
WORKDIR /root/SysML-v2-Release-2021-01/install/jupyter
ENV PATH="/usr/conda/bin:/usr/conda/condabin:/usr/local/openjdk-17/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
RUN ./install.sh
WORKDIR /root/SysML-v2-Release-2021-01/
ENTRYPOINT ["jupyter", "lab", \
"--allow-root", \
"--ip", "172.17.0.2", \
"--port", "8888"]
@gorenje
Copy link
Author

gorenje commented Feb 18, 2021

This is now moved to a repo --> https://github.com/gorenje/sysmlv2-jupyter-docker

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment