Skip to content

Example web app generated with the help of gogo-cli

Notifications You must be signed in to change notification settings

can3p/gogo-cli-example

Repository files navigation

Operational Notes for gogo-cli-example

Initial Setup

  1. change remote and push to the new repo

  2. change flytoml to point to the new app gogo-cli-example

  3. create the app on fly flyctl apps create gogo-cli-example

  4. create db, set 4gb ram fly postgres create -n gogo-cli-exampledb

  5. attach db to the app flyctl postgres attach -a gogo-cli-example gogo-cli-exampledb

  6. Set secrets:

    flyctl secrets set SESSION_SALT=<random string>
    flyctl secrets set SITE_ROOT=https://gogo-cli-example.com
    flyctl secrets set MJ_APIKEY_PUBLIC=<public key from mailjet>
    flyctl secrets set MJ_APIKEY_PRIVATE=<private key from mailjet>
    
  7. Do first deploy fly deploy, make sure you can reach the app via .fly.dev

  8. Create a cert for your custom domain fly certs add gogo-cli-example.com

  9. After it screams at you, add required A and AAAA records

  10. You might need to run fly certs check gogo-cli-example.com a couple of times, fly certs list should show your domain with the status ready.

  11. You should be able to reach your app via custom domain at this point

  12. Got to mailjet and add new domain

  13. Add sender email address there

  14. Add required txt record to validate domain

  15. Add required txt records to add DKIM and SPF settings

  16. Add postgres db env var to cmd/web/.env via ./env.pl > cmd/web/.env, remove sslMode=disable and replace domain name with localhost

  17. Run the following from the project root to get the database schema in place and generate orm files

./sqlmigrate.sh
./generate.sh

Development

cd cmd/web
yarn
yarn watch # in one tab
make watchexec # in another tab

Credits

The project has been generated by gogo-cli and uses gogo library

About

Example web app generated with the help of gogo-cli

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published