Skip to content

SafeAck/backend

Repository files navigation

SafeAck Backend

APIs for SafeAck Applications

  • Tests Status Run SafeAck API App Tests

Usage 🐦‍🔥

  • Install and configure Docker 🐋

  • Install python 🐍

  • Clone repo

    git clone https://github.com/SafeAck/backend.git
  • Usage SafeAck Deployment Manager script for managing deployment

    python sdm.py -h
  • Deploy Backend

    python sdm.py deploy

    Note: use python3 instead of python

  • Stop Backend

    python sdm.py stop
  • Start Backend. Below command needs to be used once backend has been deployed and you need to start it again.

    python sdm.py start
  • Upgrade Infra

    python sdm.py upgrade
  • Migrate Manually

    python sdm.py migrate
  • Get backend container shell access

    python sdm.py shell

Dev

Hi 👋, If you'd like to contribute to SafeAck project then below sections are for you 😎

Config

Update env and alembic.ini file when making changes to db

  • import newly generated model in safeack-backend/models.py

  • create migrations

    alembic revision --autogenerate -m "init"
  • apply migrations

    alembic upgrade head

Shell Usage

  • Trigger shell
python -m safeack_backend.scripts.shell
  • Enter python or db queries
from ..models import User
db.query(User).all()

About

SafeAck Backend Repo

Resources

Stars

Watchers

Forks

Packages

No packages published