Skip to content

Latest commit

 

History

History
55 lines (30 loc) · 1.14 KB

File metadata and controls

55 lines (30 loc) · 1.14 KB

Deploy Python Flask App on Docker Container

Step 1

 git clone https://github.com/muhammadaliazhar/PythonApp-docker.git

Step 2

docker build -t flask-app .

Step 3

docker run -d -p 80:80 flask-app
image

Step 4

Open port 80 on your instance security group ( firewall rule )

Hit public ip of your instance on a browser

image image

Step 5

Check container logs

docker logs <container-id>
image

Real-time container logs

To see real time logs of a docker container we use attach command, this will attach our host terminal with the container terminal

docker attach <container-id