These are chat archives for Fortran-FOSS-Programmers/General-Discussion
@zbeekman Maybe I found an answer
It seems that I can mount some paths of a running-docker-image into my system. If this is true, I can mount your (docker image) gfortran-PATH somewhere in my system (say /opt/zaak-gfortran/) and then load it as my other modules... I'll try later today.
Zaak, I am sorry to bother you, but docker remains ambiguous for me.
See this guide
It seems it is possible to use docker to directly run a program (the shell program whalesay in that case) in the host system, i.e.
docker run docker/whalesay cowsay 'hello Zaak'
So my new question: is it possible to dockerize gfortran in that way? say to be able to run
docker run zaak/gfortran 'foo.f90 -o foo'
-c "gfortran --version"or
-c "gfortran /path/to/mounted/source/file.f90 && /path/to/mounted/source/a.out"you should be able to use dockerized gfortran with the image as it stands
/bin/bashand the CMD is
-lwhich is the default arguments to be passed to the ENTRYPOINT. If you add extra text after
docker run ....it will replace CMD with that extra text. So you can run arbitrary commands by passing either
-c "my raw bash commands here like calls to /usr/local/bin/gfortran"or you could pass it a script that is somewhere already cross mounted with the container.
Thank you very for your kind replays.
Today I played with docker for learning aims... I tried to achieve a sort of cross-compiling without success, but I had few minutes for my tests, I hope to be more lucky tomorrow. However, I have a request for you: I tried to compose your image with another providing python 2.7, but docker-compose is really non intuitive (IMO) and it seems not so trivial at least at the beginning; can you modify your image to include a python 2.7 interpreter? Without a python interpreter I cannot use FoBiS thus my productivity becomes close to zero... having a python interpreter into your gcc docker image let me to source any virtualenv I created for each Fortran project... it will become very handy.