Skip to content

This project aims a Flask app to fetch the sample data from MYSQL DB. and Deploy using K8s.

Notifications You must be signed in to change notification settings

yadhugit/demoflask

Repository files navigation

Demo Flask App Project image image

This is a demo project to show how to deploy a two tier application using a K8s cluster ( minikube )

Pre-requisites

  • Minikube installed and running.
  • Virtualization enabled in the host.
  • Docker installed.
  • Kubectl CLI installed.

To execute the project using Minikube K8s cluster :

  1. execute below command using Minikube. :
minikube start
  1. clone the github repo using :
git clone https://github.com/yadhugit/demoflask.git
  1. change directory k8s_resources/flaskapp :
cd demoflask/k8s_resources/flaskapp
  1. Execute deployment file inside the k8s_resources/flaskapp folder respectively using k8s.
kubectl create -f deployment-svc-conf.yaml
  1. change directory k8s_resources/mysql :
cd demoflask/k8s_resources/mysql
  1. Execute deployment file inside the k8s_resources/mysql folder respectively using k8s.
kubectl create -f mysql-deploy-svc-pv.yaml

will create flask app deployment, services in your PC

  1. Use below command to get your service url,
minikube service demoflask-service --url

and open url up your default browser.

About

This project aims a Flask app to fetch the sample data from MYSQL DB. and Deploy using K8s.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published