This
-
Create a new repository with UoAWDCC as owner
-
Select repository template as
UoAWDCC/react-template -
Clone the app to your local machine
-
In
/api/fly.production.tomlchange the app name towdcc-app-name-api. For example, passport will bewdcc-passport-apiThen create the app on fly with this command:PS C:\Users\alexw\OneDrive\Documents\GitHub\UoAWDCC\passport> fly apps create --name wdcc-passport-api --org wdcc-projects New app created: wdcc-passport-api
-
In the
/apidirectory runPS C:\Users\alexw\OneDrive\Documents\GitHub\UoAWDCC\passport\api> fly tokens create deploy --config fly.production.toml FlyV1 ...IFIc=
- Copy the output to your clipboard
- Go to repository settings on Github
- In secrets and variables select actions
- Create a new repository secret
- Name it
FLY_API_PRODUCTION_API_TOKENand paste in the secret
-
In
/api/fly.staging.tomlchange the app name towdcc-app-name-api-stagingThen create the app on fly with this commandPS C:\Users\alexw\OneDrive\Documents\GitHub\UoAWDCC\passport> fly apps create --name wdcc-passport-api-staging --org wdcc-projects New app created: wdcc-passport-api-staging -
In the
/apidirectory runPS C:\Users\alexw\OneDrive\Documents\GitHub\UoAWDCC\passport\api> fly tokens create deploy --config fly.staging.toml FlyV1 ...IFIc=
- Copy the output to your clipboard
- Go to repository settings on Github
- In secrets and variables select actions
- Create a new repository secret
- Name it
FLY_API_STAGING_API_TOKENand paste in the secret
-
In
/web/Dockerfile.productionchangeENV VITE_API_URL="https://react-template-api.fly.dev"
to
ENV VITE_API_URL="https://wdcc-app-name-api.fly.dev"
(change it to to the name of your production api app that you just created before
-
In
/web/Dockerfile.stagingchangeENV VITE_API_URL="https://react-template-api-staging.fly.dev"
to
ENV VITE_API_URL="https://wdcc-app-name-api-staging.fly.dev"
(change it to to the name of your staging api app that you just created before
-
In
/web/fly.production.tomlchange the name of the app towdcc-app-nameand runfly apps create --name wdcc-app-name --org wdcc-projects -
Now run
fly tokens create deploy --config fly.production.tomland save that as a Github repository secret with the nameFLY_WEB_PRODUCTION_API_TOKEN -
In
/web/fly.staging.tomlchange the name of the app towdcc-app-name-stagingand runfly apps create --name wdcc-app-name-staging --org wdcc-projects -
Now run
fly tokens create deploy --config fly.staging.tomland save that as a Github repository secret with the nameFLY_WEB_STAGING_API_TOKEN

