Skip to content

sciencefidelity/newsletter

Repository files navigation

Newsletter

Newsletter API in Rust.

Deploy

Deploy to Digital Ocean App Platform:

doctl apps create --spec spec.yaml

Migrate database on Digital Ocean

DATABASE_URL=<digital-ocean-db-connection-string> sqlx migrate run

Update running app on Digital Ocean

# get the app id
doctl apps list

# use the id to update the app
doctl apps update <digital-ocean-app-id> --spec spec.yaml

Migrations

Run migrations with no local Docker running run from project root:

./scripts/init_db.sh

Run migrations with Docker already running set SKIP_DOCKER environment variable:

SKIP_DOCKER=true ./scripts/init_db.sh