GithubHelp home page GithubHelp logo

ondiekelijah / flask-docker-app Goto Github PK

View Code? Open in Web Editor NEW
23.0 1.0 221.0 17 KB

A quick guide on how to Dockerize a flask application.

License: MIT License

Dockerfile 54.52% Python 45.48%
flask docker-image docker-containers docker-engine

flask-docker-app's Introduction

Flask-Docker-App

Set up & Installation.

1 .Clone/Fork the git repo and create a virtual environment

Windows

git clone https://github.com/Dev-Elie/Flask-Docker-App.git
cd Flask-Docker-App
py -3 -m venv venv

macOS/Linux

git clone https://github.com/Dev-Elie/Flask-Docker-App.git
cd Flask-Docker-App
python3 -m venv venv

2 .Activate the environment

Windows

venv\Scripts\activate

macOS/Linux

. venv/bin/activate or source venv/bin/activate

3 .Install the requirements

Applies for windows/macOS/Linux

pip install -r requirements.txt

5. Run the application

python app.py

OR

Create a new application from scratch

1. Create a directory with a name "Flask-Docker-App"

mkdir Flask-Docker-App

2. Navigate to the newly created directory

cd Flask-Docker-App

3. Create a virtual environment

Windows

py -3 -m venv venv

macOS/Linux

python3 -m venv venv

4. Activate the environment

Windows

venv\Scripts\activate

macOS/Linux

. venv/bin/activate or source venv/bin/activate

3 .Install Flask

pip install Flask

4. Create the required files

Create two files; app.py and Dockerfile

touch app.py Dockerfile

Congratulations! You can now proceed with the article on Dockerizing a Flask app here.


Follow me on Twitter

dev_elie

flask-docker-app's People

Contributors

ondiekelijah avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.