Verified Commit b708b0e2 authored by Lars Bilke's avatar Lars Bilke
Browse files

[web] Added docs on Docker usage.

parent c621f3ea
...@@ -81,3 +81,31 @@ Singularity ogs-6.2.2-serial.sif:...> exit ...@@ -81,3 +81,31 @@ Singularity ogs-6.2.2-serial.sif:...> exit
* `singularity exec --app ogs ogs-xxx-gui-xxx.sif DataExplorer` * `singularity exec --app ogs ogs-xxx-gui-xxx.sif DataExplorer`
You may use this container on e.g. `envinf1` with X11 forwarding (`ssh -XY envinf1`). You may use this container on e.g. `envinf1` with X11 forwarding (`ssh -XY envinf1`).
----
## With Docker
Although Singularity is the preferred container runtime you can use [Docker](https://www.docker.com) too.
### Prerequisites
* A running [installation of Docker](https://docs.docker.com/get-docker/)
### Run OGS inside a Docker container
* Get the container: `docker pull registry.opengeosys.org/ogs/ogs/ogs-serial`
* Start interactive container session: `docker run --rm -it registry.opengeosys.org/ogs/ogs/ogs-serial`
* Run ogs: `/scif/apps/ogs/bin/ogs --version`
* Exit the container: `exit`
You will notice that the interactive session in your container is isolated from your host, i.e. you do not have access to files on your host. You need to explicitly [mount](https://docs.docker.com/storage/bind-mounts/) them on `docker run`:
```bash
mkdir ~/ogs_out
docker run --rm -it -v $HOME/code/ogs6/ogs/Tests/Data:/tmp/data:ro -v $HOME/ogs_out:/tmp/out registry.opengeosys.org/ogs/ogs/ogs-seria
/scif/apps/ogs/bin/ogs -o /tmp/out /tmp/data/Elliptic/cube_1x1x1_SteadyStateDiffusion/cube_1e4.prj
exit
ls ~/ogs_out
# [shows ogs generated output files]
```
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment