Deploy renov8
Deploy and Host renov8 with Railway
Just deployed
/var/lib/postgresql/data
Renov8 PostgreSQL Database
Renov8 is a construction and renovation project management application that helps homeowners translate project ideas and measurements into clear stages, materials, trades, and progress tracking. This database stores all project data, user accounts, material calculations, and progress photos.
About Hosting Renov8 Database
The Renov8 PostgreSQL database is the backbone of the construction management system. It stores 12 interconnected models including users, projects, phases, tasks, materials, suppliers, contractors, measurements, and photos. The database uses Prisma ORM for type-safe queries and includes automatic material cost calculations, phase dependency tracking, and multi-language support. Deploying on Railway provides automatic SSL certificates, connection pooling, and daily backups with minimal configuration.
Common Use Cases
- Construction Project Management - Track renovation projects from planning through completion with phases, tasks, and materials
- Material Cost Estimation - Automatically calculate material quantities and costs based on measurements and waste factors
- Contractor Directory - Maintain a database of suppliers and contractors with contact information and specialties
- Progress Documentation - Store and tag construction progress photos linked to specific phases and locations
Dependencies for Renov8 Hosting
- PostgreSQL 15+ - Primary database engine
- Prisma ORM - Database client and migration tool (included in backend)
- Node.js 18+ - Required for running Prisma migrations
- SSL/TLS - Secure connections (automatically provided by Railway)
Deployment Dependencies
- Prisma Documentation - ORM and database toolkit
- PostgreSQL Documentation - Database reference
- Renov8 Backend Repository - Application code
Implementation Details
Database Schema Highlights:
// Core Models (12 total)
model User {
id String @id @default(uuid())
email String @unique
password String
projects Project[]
refreshTokens RefreshToken[]
}
model Project {
id String @id @default(uuid())
name String
status ProjectStatus @default(PLANNING)
phases Phase[]
userId String
user User @relation(fields: [userId], references: [id])
}
model Material {
id String @id @default(uuid())
name String
quantity Float
unit MaterialUnit
costPerUnit Float
wasteFactor Float @default(1.1)
totalCost Float // Auto-calculated: quantity * costPerUnit * wasteFactor
}
Key Features:
- Automatic timestamps on all models (
createdAt,updatedAt) - Foreign key relationships with cascading deletes
- 10 enums for type safety (ProjectStatus, PhaseStatus, MaterialUnit, etc.)
- Material cost calculations with waste factors
- Phase dependency tracking for construction workflows
Connection String Format:
DATABASE_URL="postgresql://postgres:password@host:port/database"
After Deployment:
# Run migrations to create tables
npx prisma migrate deploy
# Generate Prisma Client
npx prisma generate
# View database in Prisma Studio
npx prisma studio
Deploy and Host
Quick Deploy on Railway
-
Click the Deploy Button (if available) or manually create a new project in Railway
-
Add PostgreSQL Service:
- Go to your Railway project
- Click "New Service" → "Database" → "PostgreSQL"
- Railway automatically provisions the database with SSL
-
Get Your Connection String:
- Navigate to the PostgreSQL service
- Click on "Variables" tab
- Copy the
DATABASE_PUBLIC_URLvalue (for local development) - Or use
DATABASE_URL(for Railway-hosted backend)
-
Configure Your Backend:
# In your backend/.env file DATABASE_URL="" JWT_SECRET="your-super-secret-key-min-32-chars" PORT=3000 NODE_ENV=development -
Run Database Migration:
cd backend npx prisma migrate deploy npx prisma generate -
Start Your Application:
npm run dev # Server should start on http://localhost:3000
Manual Deployment Steps
If deploying to Railway without the template:
- Create a new Railway project
- Add PostgreSQL database service
- Add Node.js service for your backend
- Connect the services via environment variables
- Railway will automatically build and deploy your application
Environment Variables Required
DATABASE_URL="postgresql://postgres:password@host:port/database"
JWT_SECRET="minimum-32-character-secret-key"
PORT=3000
NODE_ENV=production
Verify Deployment
After deployment, test your database connection:
# Test database connection
npx prisma db pull
# View your database in browser
npx prisma studio
Your Renov8 database is now ready to handle construction projects! 🏗️
Why Deploy Renov8 on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Renov8 on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Railway Benefits for Renov8:
- ✅ Automatic SSL certificates (820-day validity)
- ✅ Private networking between services
- ✅ Built-in connection pooling
- ✅ Automatic daily backups
- ✅ One-click PostgreSQL provisioning
- ✅ Environment variable management
- ✅ Seamless scaling as your user base grows
Template Content