Skip to content

stanvn/E-ink-Picture-Frame-Server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

E-Ink Picture Frame Server

Monorepo containing the backend API and frontend admin app for managing e-ink picture frames. The backend persists metadata in JSON files and stores original/converted assets on disk.

Prerequisites

  • Node.js 20 or newer
  • npm 9+

Repository Layout

  • backend/ Express API scaffold with JSON persistence directories in backend/data
  • frontend/ React + Vite + MUI admin shell
  • assets/original and assets/converted for uploaded and processed images
  • AI/ implementation plan and design notes

First-Time Setup

npm install --workspaces
cp backend/.env.example backend/.env

Development Scripts

  • npm run dev:backend – start Express server with nodemon (defaults to port 4000)
  • npm run dev:frontend – start Vite dev server for the React app (port 3000, proxies /api)
  • npm run lint – run ESLint in all workspaces
  • npm run test --workspace backend – run Jest API tests
  • npm run test --workspace frontend – run Vitest + React Testing Library smoke tests

Running the Backend

  1. Copy environment defaults if you have not already: cp backend/.env.example backend/.env
  2. Start the API: npm run dev:backend
  3. Access the health check at http://localhost:4000/health
  4. Frame endpoints live under http://localhost:4000/api/frames
  5. Photo upload and metadata endpoints are available at http://localhost:4000/api/photos

Environment Variables

backend/.env

  • PORT – HTTP port (default 4000)
  • ASSETS_DIR – relative path to the assets root (../assets by default)
  • DATA_DIR – path to JSON persistence directory (./data by default)

frontend/.env (optional)

  • VITE_API_BASE_URL – override the backend URL used by the API client (default http://localhost:4000)

Next Steps

Move on to AI/step05_frontend_feature_pages.md to start building the dedicated frame and photo workflows on top of the shared foundation.

About

Server to convert images to e-ink png files that can be used with an ESPHome E-Ink picture frame

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published