Skip to content

Latest commit

Β 

History

History
99 lines (75 loc) Β· 2.26 KB

File metadata and controls

99 lines (75 loc) Β· 2.26 KB

Digital Ocean Deployment Options

πŸš€ App Platform (Recommended)

Cost: Free tier available, then $12/month for basic plan

Pros:

  • βœ… Managed platform (like Render)
  • βœ… Auto-scaling
  • βœ… Built-in SSL
  • βœ… Easy deployment from GitHub
  • βœ… Good for WebSocket apps

Cons:

  • ❌ More expensive than Render's free tier
  • ❌ May sleep on free tier

Deploy Steps:

  1. Go to digitalocean.com
  2. Create account
  3. Create β†’ Apps
  4. Connect GitHub repo
  5. Configure:
    Source: GitHub
    Branch: main
    Source Directory: server
    Run Command: npm start
    HTTP Port: 3001
    
  6. Add environment: NODE_ENV=production
  7. Deploy

πŸ–₯️ Droplets (VPS)

Cost: $6/month (Basic plan)

Pros:

  • βœ… Full control over server
  • βœ… Always running (no sleeping)
  • βœ… Cheapest persistent hosting
  • βœ… Can run multiple apps

Cons:

  • ❌ Requires server management
  • ❌ Manual SSL setup
  • ❌ More complex setup

Quick Setup:

# On your local machine
ssh root@your-droplet-ip

# On the server
git clone https://github.com/PATILYASHH/Party-player.git
cd Party-player/server
npm install
npm start

# Keep running with PM2
npm install -g pm2
pm2 start index.js --name watch-party
pm2 save
pm2 startup

⚑ Functions (Serverless)

Cost: Pay per execution

Pros:

  • βœ… Auto-scaling
  • βœ… No server management

Cons:

  • ❌ Not suitable for WebSockets
  • ❌ Execution time limits
  • ❌ Stateless (can't maintain connections)

πŸ“Š Comparison

Platform Cost WebSocket Support Ease of Use Always Online
Render Free (750h/month) βœ… Excellent βœ… Very Easy ⚠️ Sleeps
DigitalOcean App $12/month βœ… Good βœ… Easy βœ… Yes
DigitalOcean Droplet $6/month βœ… Excellent ⚠️ Medium βœ… Yes
Railway $5 credit βœ… Excellent βœ… Easy βœ… Yes

πŸ’‘ Recommendation

For your needs: DigitalOcean Droplet ($6/month) gives you the best value - persistent connections, full control, and cheapest long-term hosting.

Quick start: App Platform if you want simplicity, Droplet if you want control and lowest cost.