---
title: "Deploy renov8"
description: "Deploy and Host renov8 with Railway"
category: "Storage"
url: https://railway.com/deploy/renov8
---

# Deploy renov8

Deploy and Host renov8 with Railway

**[Deploy renov8 on Railway](https://railway.com/template/renov8)**

- **Creator:** chaimPaneth's Projects
- **Category:** Storage

## Template content

### Postgres https://devicons.railway.app/i/postgresql.svg

- **Image:** ghcr.io/railwayapp-templates/postgres-ssl:17

## Documentation

# 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](https://www.prisma.io/docs) - ORM and database toolkit
- [PostgreSQL Documentation](https://www.postgresql.org/docs/) - Database reference
- [Renov8 Backend Repository](https://github.com/youruser/renov8) - Application code

### Implementation Details

**Database Schema Highlights:**

```prisma
// 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:**
```bash
DATABASE_URL="postgresql://postgres:password@host:port/database"
```

**After Deployment:**
```bash
# 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

1. **Click the Deploy Button** (if available) or manually create a new project in Railway
2. **Add PostgreSQL Service**:
   - Go to your Railway project
   - Click "New Service" → "Database" → "PostgreSQL"
   - Railway automatically provisions the database with SSL

3. **Get Your Connection String**:
   - Navigate to the PostgreSQL service
   - Click on "Variables" tab
   - Copy the `DATABASE_PUBLIC_URL` value (for local development)
   - Or use `DATABASE_URL` (for Railway-hosted backend)

4. **Configure Your Backend**:
   ```bash
   # In your backend/.env file
   DATABASE_URL=""
   JWT_SECRET="your-super-secret-key-min-32-chars"
   PORT=3000
   NODE_ENV=development
   ```

5. **Run Database Migration**:
   ```bash
   cd backend
   npx prisma migrate deploy
   npx prisma generate
   ```

6. **Start Your Application**:
   ```bash
   npm run dev
   # Server should start on http://localhost:3000
   ```

### Manual Deployment Steps

If deploying to Railway without the template:

1. Create a new Railway project
2. Add PostgreSQL database service
3. Add Node.js service for your backend
4. Connect the services via environment variables
5. Railway will automatically build and deploy your application

### Environment Variables Required

```bash
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:

```bash
# 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


## Similar templates

- [Garage S3 Storage](https://railway.com/deploy/garage-s3-storage) — Ultra-light S3 server: fast, open-source, plug-and-play.
- [Redis](https://railway.com/deploy/redis-1) — Self Host Latest Redis with Railway
- [EasyImg](https://railway.com/deploy/easyimg) — Simple self-hostable Nuxt.js personal image hosting system.

Open this page in a browser: https://railway.com/deploy/renov8
