GithubHelp home page GithubHelp logo

doct-cbd3345-dictionary's Introduction

doct-cbd3324-backend

Containerization and Container Delivery - Backend Application

Structure

doct-cbd3324-backend/           
├── app/                        # Python Flask application path
│   ├── main.py                 # Python Web Application code
│   └── ...
├── k8s/                        # K8s folder
│   ├── helm/                   # Helm structure path
│   │   ├── dictionary/         # Dictionary chart
│   │   ├── mongodb/            # MongoDB chart
│   │   ├── rbac/               # RBAC chart
│   │   ├── values.yaml         # Charts share value file
|   |   └── ...
│   └── manifests/
|       ├── dictionary/         # Dictionary manifest files
|       ├── mongodb/            # MongoDB manifest files
|       ├── rback/              # RBAC manifest files
|       ├── configmaps-prd.yml  # ConfigMap config for PRD
|       ├── configmaps.yml      # ConfigMap config for UAT
|       ├── namespace-prd.yml   # Namespace config for PRD
|       ├── namespace.yml       # Namespace config for UAT
|       ├── secrets.yml         # Secret config file
|       └── ...
├── tests/
│   ├── __init__.py             # Module structure file
│   ├── test_app_json.py        # Python unit test file
├── .gitignore                  # Excluded Files List for Git
├── docker-compose.yml          # Docker Compose file for multi-container
├── Dockerfile                  # Dockerfile to build an image
├── README.md                   # This readme file
├── requirements.txt            # Python dependencies requirement
└── ...

Dependencies Installation

pip install -r requirements.txt

Run the application

python3 app/main.py

Build and Run Docker Container

To build an image, use the command

docker build -t apinyarr/dic-backend:test .

To run a container, use the command

docker run -d --rm --name dic-backend -p 8088:8088 -e MONGODB_HOST=host.docker.internal apinyarr/dic-backend:test

Run using Docker Compose

To run using Docker Compose (explicit the compose file name)

docker compose -f docker-compose.yaml up -d

Run using Kubernetes

Starting order

Remark Skip step 1 if dictionary-namespace is created

  1. Create namespace dictionary-namespace

kubectl apply -f namespace.yaml

Remark Skip step 2 if dic-config is created 2. Create configMap dic-config

kubectl apply -f configmaps.yaml

  1. Create deployment dic-mongodb-deployment

kubectl apply -f mongodb/mongodb-deployment.yaml

  1. Create service dic-mongodb-service

kubectl apply -f mongodb/mongodb-service.yaml

  1. Create deployment dic-backend-deployment

kubectl apply -f backend/backend-deployment.yaml

  1. Create service dic-backend-service

kubectl apply -f backend/backend-service.yaml

doct-cbd3345-dictionary's People

Contributors

apinyarr avatar rohitrana043 avatar jinnied avatar

Watchers

 avatar

Forkers

jinnied

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.