Skip to content

Latest commit

 

History

History
95 lines (65 loc) · 1.61 KB

readme.md

File metadata and controls

95 lines (65 loc) · 1.61 KB

Kubernetes API CRUD operation using Django with React

Tech Spec

Database - Postgres Logs APM - SigNoz (attached screenshot above)

Access the app at - http://localhost:3000/applications

Run Frontend

  1. yarn install
  2. yarn start

Run backend

  1. celery -A k8sapi worker
  2. redis-server
  3. python manage.py runserver
  4. python manage.py migrate/makemigrations (optional, if you are setting it up for the first time)

Commands to run

  1. python manage.py makemigrations
  2. python manage.py migrate
  3. python manage.py runserver
  4. start redis server - redis-server
  5. start celery - celery -A k8sapi worker
  6. Start frontend and backend
  7. Hit the API mentioned below with dummy data
  8. You'll see the details in the UI.

Pod Logs in SigNoz and UI

APIS

GET

http://127.0.0.1:8000/deploy/deploy-list

http://127.0.0.1:8000/deploy/apps/1/logs/

POST

http://127.0.0.1:8000/deploy/

{
    "namespace": "example-namespace2",
    "application_name": "ahoy",
    "chart_name": "hello-world",
    "chart_version": "1.0.2"
}

http://127.0.0.1:8000/authen/login/

{
        "email": "[email protected]",
        "password": "Password@123"
}

http://127.0.0.1:8000/authen/signup/

{
        "username": "testuser2",
        "email": "[email protected]",
        "password": "Password@123"
}

DELETE

http://127.0.0.1:8000/deploy/apps/int:id/

.env file sample

DATABASE_NAME=scoutflo
DATABASE_USER=postgres  
DATABASE_PASSWORD=postgres
DATABASE_HOST=localhost
DATABASE_HOST=my-release-psql-postgresql
DATABASE_PORT=5432