Skip to content

fileverse/api-heroku-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

API Heroku Template

One-click deployment template for Fileverse API - a document management system with sync.

Deploy

Prerequisites

Before deploying, you'll need:

  1. Storage Server API Key - API key for the storage server authentication

Environment Variables

Variable Required Description Default
API_KEY Yes Storage server authentication key -
DATABASE_URL Auto PostgreSQL connection string (set by Heroku Postgres addon) -
RPC_URL No Ethereum RPC endpoint https://rpc.sepolia.org
INLINE_WORKER No Run worker in same process true
PORT Auto Automatically set by Heroku -

Architecture

This template deploys a single web dyno with Heroku Postgres that runs both:

  • API Server: REST API for document management
  • Worker: Background process for sync jobs

Both run in the same process (via INLINE_WORKER=true). The Heroku Postgres addon is automatically provisioned and DATABASE_URL is set by Heroku, so data persists across dyno restarts and deployments.

Post-Deployment Setup

  1. After deployment, verify the dyno is running:

    heroku ps
  2. Check the logs for any startup issues:

    heroku logs --tail

Local Development

To run locally:

npm install
export DATABASE_URL="postgresql://localhost:5432/fileverse"
export API_KEY="your-api-key"
npm start

License

ISC

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors