Hive prototype, lihive meets rust backend
- rust/cargo
- nodejs
- a Firebase project w/ Authentication setup
- Sign-in providers enabled:
- Anonymous
- Sign-in providers enabled:
- a Postgres database
- Setup a Firebase project as defined above, making note of its Web API key, project ID, and project auth domain
- Create an
.env.local
file for the frontend:
js/frontend/.env.local
NEXT_PUBLIC_FIREBASE_API_KEY=
NEXT_PUBLIC_FIREBASE_AUTH_DOMAIN=
NEXT_PUBLIC_FIREBASE_PROJECT_ID="
- Build the static frontend files:
$ npm install
$ npm run --workspace js/frontend build
- Create a
.env
file for the backend:
backend/.env
DATABASE_URL= # whatever the connection string for your Postgres database is
FIREBASE_JWT_ISSUER= # this should be the same as your Firebase auth domain
STATIC_FILES_PATH=./dist # we'll set this up in a moment
- Run the Diesel migrations, if you haven't already:
$ cd backend
$ diesel migration run
- Run the backend server:
$ cd backend
$ cargo run