Skip to content

Commit

Permalink
Update Readme.md about docker
Browse files Browse the repository at this point in the history
  • Loading branch information
SchetininVitaliy committed Aug 10, 2022
1 parent d6e72b9 commit ccff8fb
Showing 1 changed file with 5 additions and 24 deletions.
29 changes: 5 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,30 +52,7 @@ git checkout dev
docker build --build-arg ER=dev -t er .
```

4. Enjoy _ROOT_, _Go4_, _AccDAQ_ and _ER_:

* To run simulation in interactive session:

```
docker run -v /home/vitaliy/er/macro/EXP1904_H7:/opt/run -w /opt/run -e DISPLAY=$DISPLAY -it er /bin/bash
root -l -q create_passive_component.C
root -l -q create_target_exp1904.C
root -l -q sim_digi.C
root -l sim_digi.root
```
where -v is used to map your host working directory '/home/vitaliy/er/macro/EXP1904_H7' and working
directory '/opt/run' inside container; -w /opt/run - set working directory for interactive session;
-e DISPLAY=$DISPLAY is needed to forward gui from container to host machine; -it - to set interactive session.

* To run macro in batch mode:

```
docker run -v /Users/vitaliy/er/macro/EXP1904_H7:/opt/run -w /opt/run er root -l -b -q create_passive_component.C
```

5. _ER_ developing:

Map _ER_ source directory on host machine and container to compile updated sources:
4. Run _er_ container, compile updated sources, run simulation:

```
docker run --entrypoint /bin/bash -v /home/vitaliy/er:/opt/er -v /home/vitaliy/er/macro/EXP1904_H7:/opt/run -w /opt/run -e DISPLAY=$DISPLAY -it er
Expand All @@ -92,6 +69,10 @@ cd /opt/run/
root -l sim_digi.C
```

where -v is used to map your host working directory '/home/vitaliy/er/macro/EXP1904_H7' and working
directory '/opt/run' inside container; -w /opt/run - set working directory for interactive session;
-e DISPLAY=$DISPLAY is needed to forward gui from container to host machine; -it - to set interactive session.

Redifinition of `entrypoint` is needed because `er/build/config.sh` may not exists in mapped volume.

## Step by Step installation
Expand Down

0 comments on commit ccff8fb

Please sign in to comment.