Sign inSign up

carinamarina/hello-world-web

By carinamarina

•Updated about 10 years ago

A Python web app, running on port 5000, which prints data from a linked container.

Image
1

8.0K

carinamarina/hello-world-web repository overview

⁠Hello World Web

This is a sample Python web application, running on port 5000, which prints data retrieved from the linked carinamarina/hello-world-app container.

  1. Run the carinamarina/hello-world-app container.

    docker run --detach --name app carinamarina/hello-world-app
    
  2. Run the carinamarina/hello-world-web container, linking to the app container using the alias helloapp.

    docker run --detach --name web --link app:helloapp --publish-all carinamarina/hello-world-web
    
  3. Identity the port where the web container was published. In the example below, the port is 32770.

    $ docker port web
    5000/tcp -> 0.0.0.0:32770
    
  4. Open http://<dockerHost>:<appContainerPort>, for example http://localhost:32770⁠. You should see the following output:

    The linked container says ... "Hello World!"
    

Tag summary

Content type

Image

Digest

sha256:68eec9021…

Size

257.2 MB

Last updated

about 10 years ago

docker pull carinamarina/hello-world-web