Local Development
Prerequisites
Local SSL Certificates
For better production / development parity and less complexity, this project requires SSL certificates for local development.
Run the following command to create the certificate in your $HOME/certs directory
./create-certificate local.comNow you should have the certificates under $HOME/certs ready to use.
Dashboard Application Environment Variables
Create a .env file under in the fe-dashboard application directory.
You can create it from the fe-dashboard/.env.example file.
Main Environment Variables
Create a .env in the repository root directory.
You can create it from the .env.example file.
Start Developing
Now you are ready to start the env environment with the following command:
make developThis command watches file changes, builds and runs the docker-compose.yaml continuously.
This should be enough for development in the backend golang services but when you are working on the frontend services you will want to run an additional pnpm run dev in the respective application directories fe-dashboard or fe-website
Google
For the "Login with Google" feature you will need to prepare the Google Cloud project ID and secret.
- Sign-in to your Google Cloud account
- Create or pick an existing project
- Search / Open "APIs and Services"
- Navigate to "Credentials" from the left sidebar navigation
- Under "Create Credentials" Choose the option "OAuth client ID"
- Pick "Web Application" as the type
- Configure "Authorized JavaScript origins" with
https://local.com - Configure "Authorized redirect URIs" with
https://local.com/app/auth/oauth/google
After you have the project ID and secret, you will need to set those values in the repository root .env
GOOGLE_CLIENT_ID=""
GOOGLE_SECRET=""Stripe
For running payments locally you will need a stripe secret and webhook secret from a stripe test account.
Read the Stripe docs to understand how to obtain the secrets
You will need to set these env variables in the repository root .env
STRIPE_SECRET_KEY=""
STRIPE_WEBHOOK_SECRET=""
STRIPE_PK=""
STRIPE_DEFAULT_CURRENCY=usdYou will also need to run a local webhook listener with the following commands
stripe loginstripe listen --forward-to https://local.com/api/v1/payments/stripe/webhook --latest