Skip to content

Carbonable/carbonable-home

Repository files navigation

Carbonable Homepage

Carbonable homepage written in React with Remix

Usage

Set up the project

📦 Install the requirements

fly auth signup

env

DATABASE_URL="postgresql://postgres:@localhost:5432/carbonable_home?schema=public"

DAPP_URL=https://testnet.carbonable.io

SESSION_EXPIRATION_IN_SECONDS=""
SESSIONS_SECRETS=""
HASH_SECRET=""
ENABLE_EMAIL_VERIFICATION=true/false

MAILJS_PUBLIC_KEY=""
MAILJS_PRIVATE_KEY=""
MAILJS_SERVICE_ID=""
MAILJS_TEMPLATE_ID=""

🎉 Install

npm install

⛏️ Run for dev

npm run dev

💾 Database

Dev

Installation

Install Postgres

Start Postgres

Create a database named carbonable_dapp

Connection

Connection with pgAdmin: localhost:5432 postgres/[password]

Build database
# Push database schema locally
npx prisma db push

# Seed database
npx ts-node prisma/seed.ts

# Create migration file
npx prisma migrate dev --name [name of the migration]

If your database gets messed up, you can always delete the prisma/dev.db file and run npx prisma db push again. Remember to also restart your dev server with npm run dev.

Distant database

Connection
flyctl proxy 15432:5432 dev-carbonable-db.internal

Connection with pgAdmin: localhost:543154322 postgres/[password]