Skip to content

p10r/the-monolith

Repository files navigation

Local Development

  • install .direnv
  • install Lefthook
  • install nilaway
  • run lefthook install to set up pre-commit hooks
  • copy .envrc-example to .envrc, adjusting the values
  • run direnv allow .
  • run go run cmd/main.go
  • a new local.db will be created in local/

Deployment

docker build -t monolith .
# to inspect:
docker run -it monolith

docker run monolith

fly launch
fly volume create monolithvolume -r ams -n 1
fly deploy
fly logs

Connecting to Prod DB

Since sqlite is file based, we can simply download the db. For that to work, follow this thread: fly.io forum Here's another article.

cd prod/
scp root@<app name in fly.toml>.internal:/data/monolith.db .
scp root@<app name in fly.toml>.internal:/data/monolith.db-shm .
scp root@<app name in fly.toml>.internal:/data/monolith.db-wal .

TODOs

About

Baggage of side projects, bundled into one executable

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages