pnpm
can be installed by simply running:
npm install -g pnpm
Then, install all packages using pnpm i
.
Copy the .env.template
into a .env
file and fill out the values.
Key | Description |
---|---|
GOOGLE_CLIENT_ID GOOGLE_CLIENT_SECRET |
Google OAuth Client ID and Secret. Learn more at: https://developers.google.com/identity/protocols/oauth2 |
NEXTAUTH_URL |
Base URL of website. If developing locally, this would be http://localhost:3000 |
NEXTAUTH_SECRET |
A random string of letters and numbers for Next Auth to process with. Can generate one by running the following in terminal:$ openssl rand -base64 32 |
DEFAULT_REGION AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY |
AWS environment variables. |
STAGING_ENV |
The staging environment that the website is currently running in. Used for calling the correct AWS Lambda functions. In development, this would simply be 'dev'. |
You can start the development server using:
pnpm dev
The development server will compile in realtime, so any changes you make will be reflected live.
Open http://localhost:3000 with your browser to see the result.
Testing is handled by the Cypress library. To run the tests, simply run pnpm cypress:run
.
Alternatively, if you would like to spin up a browser instance and have a GUI for running cypress like
the one below, run pnpm cypress:open
.
Important
If you are using WSL, the GUI requires WSL to be setup to handle GUI applications. Follow this guide to set this up.
If you are using a native Linux, Windows or macOS machine, then there is no need to perform this step.
Deployment is automatically handled by AWS Amplify. You can access the deployment here.