Skip to content

Commit

Permalink
fixed home-access for singularity-support 🍞
Browse files Browse the repository at this point in the history
  • Loading branch information
Lukas113 committed Jun 21, 2024
1 parent dffa1c9 commit 597de50
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ RUN echo "source $BASH_ENV" >> /etc/bash.bashrc && \
RUN echo "$CONDA_PREFIX"/lib > /etc/ld.so.conf.d/conda.conf && \
ldconfig

# allow access to all users to home-dir for singularity support (shouldn't be an issue?)
RUN chmod 777 -R /home/karabo

# Additional setup
USER karabo
ENTRYPOINT ["conda", "run", "--no-capture-output", "-n", "karabo"]
6 changes: 3 additions & 3 deletions doc/src/container.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,16 @@ There's a `karabo` user set per default in the container from Karabo >= `v0.26.0


```shell
docker run --rm --user <docker-user>:$(id -u):$(id -g) -v <local-dir>:<container-dir> -p <local-port>:<container-port> <registry>/<repository>/<image-name>:<tag> bash -c <command>
docker run --rm --user <container-user>:<uid>:<gid> -v <local-dir>:<container-dir> -p <local-port>:<container-port> <registry>/<repository>/<image-name>:<tag> bash -c <command>
```

which could results in something like launching a jupyter-notebook:
which could results in something like launching a jupyter-notebook and destroying the container after termination:

```shell
docker run --rm --user karabo:$(id -u):$(id -g) -p 8888:8888 ghcr.io/i4ds/karabo-pipeline:latest bash -c 'jupyter lab --ip 0.0.0.0 --no-browser --port=8888'
```

This starts a port-forwarded jupyter-lab server in the container, accessible through a browser using the printed URL.
This starts a port-forwarded jupyter-lab server in the container, accessible through a browser using the printed URL. If you're operating on a remote server, don't forget to port-forwarding through SSH.

## Singularity Containers

Expand Down

0 comments on commit 597de50

Please sign in to comment.