call a script file from one docker container to another container using –link container

I have created a container with a name of “tensorflowsyntaxnet_container” using docker command docker run -d -name tensorflow_syntaxnet_container syntaxnet_image and the other container “python_flask” with linking the tensorflow-syntaxnet_container using docker command docker run -d -p --link tensorflow-syntaxnet_container:syntaxnet -name python_flask python_image:latest and both the containers are create successfully and its working as expected individually.

Also verified that python_flask container lined with syntaxnet container as cat /etc/hosts results syntaxnet e002ab9f43a7 tensorflow-syntaxnet_container which is container ip of syntaxnet container.

  • debootstrap inside a docker container
  • replica Set mongo docker-compose
  • Golang websocket server on docker container won't send out message to outside world
  • docker service create image command like `docker run`
  • Cannot start some containers after restarting docker daemon
  • How can I set a static IP address in a Docker container?
  • i need call a script file and need to access output file in connect with tensorflow-syntaxnet_container from my python flask application located at python_flask container

    i could not find any mount directory or folder of linked container tensorflow-syntaxnet_container

    Could any one can help me out how to call the script file and access all file from one container to another

  • link docker containers and use wildcard subdomains
  • ssl certificate for private docker repository
  • DC/OS on top of a docker container cluster
  • Using Kubernetes or Apache mesos
  • How can I get docker container root's password
  • Error running `drone exec` on Windows 10
  • 2 Solutions collect form web for “call a script file from one docker container to another container using –link container”

    Check it here Docker Link Docks
    and here Docker Volume Docs

    With --link you only can link network interfaces of container. If you want to share filesystem, you will, probably, need --volumes-from.

    docker create -v /path/to/script/dir --name scriptstore image1:name
    docker run -d --volumes-from scriptstore --name runner image2:name bash /path/to/script/dir/

    Linking two containers enables network communication. What you want are volumes:

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.