crest-cassia / oacis_docker

Dockerfile for OACIS
5 stars 3 forks source link

`bundle: command not found` when setting up the simulator following the README #88

Closed erinaldi closed 2 years ago

erinaldi commented 2 years ago

Summary

Following the instructions in the main README file I have started the oacis_jupyter container with

docker run --name my_oacis -p 127.0.0.1:3000:3000 -p 127.0.0.1:8888:8888 -dt oacis/oacis_jupyter

It started as expected and I could exec into it. I could also reach the main dashboard as can be seen in the screenshot:

Screen Shot 2022-01-19 at 16 22 36

When I try to setup the simulator using the script provided and the command

docker exec -t -u oacis my_oacis bash /home/oacis/setup_ns_model.sh

I get an error about bundle being missing.

Report

Here is the full output of the simulator setup command

+ git clone https://github.com/yohm/nagel_schreckenberg_model.git
Cloning into 'nagel_schreckenberg_model'...
remote: Enumerating objects: 66, done.
remote: Counting objects: 100% (3/3), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 66 (delta 0), reused 2 (delta 0), pack-reused 63
Unpacking objects: 100% (66/66), done.
+ cd nagel_schreckenberg_model
+ bundle install
/home/oacis/setup_ns_model.sh: line 5: bundle: command not found
yohm commented 2 years ago

Thank you for reporting this issue. The command on README was wrong. It should be

docker exec -t -u oacis my_oacis bash -l /home/oacis/setup_ns_model.sh

to launch bash as a login shell and load .bash_profile to set up environment variables.

yohm commented 2 years ago

The readme is fixed by #89.

erinaldi commented 2 years ago

Thank you. The new command works and here is the output:

(base) physics:Projects$ docker exec -t -u oacis my_oacis bash -l /home/oacis/setup_ns_model.sh
+ git clone https://github.com/yohm/nagel_schreckenberg_model.git
Cloning into 'nagel_schreckenberg_model'...
remote: Enumerating objects: 66, done.
remote: Counting objects: 100% (3/3), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 66 (delta 0), reused 2 (delta 0), pack-reused 63
Unpacking objects: 100% (66/66), done.
+ cd nagel_schreckenberg_model
+ bundle install
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Using bundler 2.2.16
Using chunky_png 1.4.0
Bundle complete! 1 Gemfile dependency, 2 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
+ /home/oacis/oacis/bin/oacis_ruby register_on_oacis.rb
Screen Shot 2022-01-20 at 9 33 31

After this, the simulator shows up on the dashboard.