Open Neznakomec opened 2 years ago
I've tried to change launch command a bit
from
CMD ["/root/scripts/run.sh"]
to
CMD ["bash", "/root/scripts/run.sh"]
Script is launching now, but I have an error ib-gateway-docker-ib-gateway-1 | /root/scripts/run.sh: line 2: $'\r': command not found ib-gateway-docker-ib-gateway-1 | /root/scripts/run.sh: line 4: $'\r': command not found ib-gateway-docker-ib-gateway-1 | /root/scripts/run.sh: line 6: $'\r': command not found ib-gateway-docker-ib-gateway-1 | /root/scripts/run.sh: line 7: $'\r': command not found ib-gateway-docker-ib-gateway-1 | /root/scripts/run.sh: line 20: syntax error: unexpected end of file ib-gateway-docker-ib-gateway-1 exited with code 2
It seems that image totally not compatible for 'Docker for Windows'
Oh, I found a source of errors - conversion to Windows line endings when git clone
a repository
https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings
It's very bad line endings for Docker and *.sh scripts
I tried to download zip archive from github and replace all files, and now it works!
I can't run the docker container and can't figure why it happen, cause container have a /scripts/run.sh file inside it