This repository contains a basic Flask application that can be built and run inside a Multistage Docker container.
Follow the steps below to clone the repository, build the Docker image, and run the Flask application.
First, clone the repository to your local machine using the following command:
git clone https://github.com/DeepDN/Sample_Flask_app.git
Move into the project directory:
cd Sample_Flask_app.git
Build the Docker image from the Dockerfile using this command:
docker build -t flask-app .
Verify that the Docker image was built successfully:
docker images
Run the Docker container, mapping port 5000 of the container to port 5000 on your local machine:
docker run -d -p 5000:5000 flask-app:latest
Open your browser and visit the following URL:
http://localhost:5000
You should now be able to see the Flask app running in your browser.
If you want to run the Flask app directly without Docker, use the following command:
python app.py
This README.md
file gives clear instructions on how to set up and run the Flask app with Docker.