Skip to content

gpadres/docker_python

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

First example of Docker with Python Flask app

  1. Build image docker build --tag=friendlyhello .

  2. Check for images docker image ls

  3. Run image docker run -p 4000:80 friendlyhello

    Note: the -p maps the host's port 4000 to the container port 80.

  4. From host computer, via a browser window access Flask App on address localhost:4000

  5. Hit CTRL+C to quit in the terminal.

Alternatively:

  1. Run image in detached mode: docker run -d -p 4000:80 friendlyhello

  2. List containers that are running docker ps. Look for the CONTAINER_ID that is running.

  3. Stop container docker container stop <CONTAINER_ID>

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors