Questo funziona:finestra mobile gestito -i -t immagine/bin/bash - file prima fonte
# echo 1 and exit:
$ docker run -i -t image /bin/bash -c "echo 1"
1
# exit
# echo 1 and return shell in docker container:
$ docker run -i -t image /bin/bash -c "echo 1; /bin/bash"
1
[email protected]:/#
Domanda: come potrei source
un file nella shell? (questo non funziona)
$ docker run -i -t image /bin/bash -c "source <(curl -Ls git.io/apeepg) && /bin/bash"
# content from http://git.io/apeepg is sourced and shell is returned
[email protected]:/#
'source' è un built-in. Non esiste come 'comando', quindi questo dà solo un errore. – Gerrat