This code is full stack app for the Age of Fallen Empires, a homebrew setting for Pathfinder 2e. The app is written in Next.js, using TypeScript, and deployed to Vercel.
- Next.js framework
- Based on React
- Using TypeScript
- CSS powered by Tailwind
- Storing data in Postgres database
- Deployed to Vercel
- Authenticated via Auth0
First, create .env file in the root folder of the app, containing followind variables:
AUTH0_SECRET=
AUTH0_BASE_URL=
AUTH0_ISSUER_BASE_URL=
AUTH0_CLIENT_ID=
AUTH0_CLIENT_SECRET=
DATABASE_PORT=
POSTGRES_PASSWORD=
POSTGRES_USER=
POSTGRES_DB=
POSTGRES_HOST=
POSTGRES_HOSTNAME=
PGADMIN_DEFAULT_EMAIL=
PGADMIN_DEFAULT_PASSWORD=
LOCAL_DATABASE_URL=
Next, set up database locally. Open the app folder and run
cd src/db
docker compose up -d
Next, run migrations using command
npm run migrate
Restore all node packages running
npm run install
And run the app in development mode using
npm run dev
Open http://localhost:3000 with your browser to see the result.