Skip to content

zebbra/timetracker

Repository files navigation

Medi Timetracker

Build Status

Combined repository for the timetracker application developed for medi.

Production Setup

This project is managed with helm v3

  1. Create shared namespace

    kubectl create ns medi
  2. Copy secrets from 1Password medi-secrets to

    • deploy/secrets.yaml
  3. Deploy secrets

    kubectl apply -n medi -f deploy/secrets.yaml
  4. Deploy Helm chart

    cd deploy && helmfile apply

Deployment

Push to master branch will trigger new deployment on k8s.

Database backup and restore

Requirements: make sure the .env file exists in the backend folder with the environment variables from deploy/secrets.yaml

Commands:

# dump the timetracker collection from mongoDB atlas cluster
# and upload it to amazon s3 bucket
yarn db:backup

# download latest backup from the specified amazon s3 bucket
# and restore it to mongoDB atlas cluster
# bucket is optional and per default set to medi-timetracker-backup
yarn db:restore <bucket>