When ENV['USER'] is not set, SSH commands are not properly executed because Net::SSH module seems to refer to ENV['USER'] instead of $(whoami) to get the user name.
In the current docker container, ENV['USER'] is somehow left unset in the shell started by docker exec -it -u oacis my_oacis /bin/bash -l command. Thus, saving a Host object fails because the validation of host parameters fails, which prevents us from registering a new simulator using APIs.
To dissolve this problem, we set ENV['USER'] in .bash_profile to ensure that the environment variable is properly set.
When ENV['USER'] is not set, SSH commands are not properly executed because Net::SSH module seems to refer to ENV['USER'] instead of
$(whoami)
to get the user name. In the current docker container, ENV['USER'] is somehow left unset in the shell started bydocker exec -it -u oacis my_oacis /bin/bash -l
command. Thus, saving a Host object fails because the validation of host parameters fails, which prevents us from registering a new simulator using APIs.To dissolve this problem, we set
ENV['USER']
in .bash_profile to ensure that the environment variable is properly set.