Skip to content

therexroder/schedule-web

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Schedule Web ⚡️

Fast, lightweight job scheduler with a modern UI 🚀

  • Backend: FastAPI + APScheduler + SQLAlchemy (SQLite)
  • Frontend: React + Vite + TypeScript + Tailwind

OpenAPI docs 📘: when the backend is running, visit http://localhost:8001/docs.

Frontend screenshot

Features

  • ⏱️ Job types: interval, one‑off date, and manual (run‑once)
  • ⌨️ Shell actions with optional cwd, env, and timeout
  • ⏸️/▶️ Pause, resume, and update existing jobs
  • 📜 Run history with status, timing, stdout/stderr, and errors
  • 🖥️ Clean UI with run logs and quick filtering

Tech Stack 🧰

  • Backend: FastAPI, APScheduler, SQLAlchemy, Uvicorn
  • Frontend: React, Vite, @tanstack/react-query, Tailwind
  • Tooling: uv for Python deps, pytest for tests, ruff for lint/format

Project Structure

src/
  backend/              # FastAPI app + scheduler + DB models
    app/                # FastAPI app, schemas, state
    routers/            # /api/jobs, /api/runs endpoints
    scheduler/          # APScheduler setup + triggers + recorder
    db/                 # SQLAlchemy engine + models
    jobs/               # Shell command job implementation
    tests/              # Pytest suite (isolated temp DB)
  frontend/             # Vite + React app (UI)
    src/client/         # Generated OpenAPI client + react-query wrappers
scripts/                # Dev helpers (start backend/frontend/fullstack)
config.toml             # App config (DB path, logging, etc.)

Quickstart ▶️

Prerequisites:

  • Python 3.13+ and uv installed (pip install uv)
  • Node.js 18+ and npm

Start everything (backend + frontend):

./scripts/start_fullstack.sh

Start individually:

  • ./scripts/start_backend.sh — syncs deps with uv and runs Uvicorn on :8001
  • ./scripts/start_frontend.sh — installs deps if needed and runs Vite on :5173

Configuration 🛠️

App settings live in config.toml at the repo root. Relative paths are resolved from the repo root.

[database]
path = "./data/app.db"

[app]
debug = false
host = "127.0.0.1"
port = 8000

[logging]
level = "INFO"
format = "%(asctime)s - %(name)s - %(levelname)s - %(message)s"

Tests use an isolated temp config via backend.config.set_config_path, so your local database is not touched when running pytest.

API

The API is fully documented via OpenAPI at http://localhost:8001/docs. Use the interactive docs to explore endpoints and schemas.

Frontend 🎨

  • Location: src/frontend/
  • Dev: from src/frontend/ run npm run dev (or use ./scripts/start_frontend.sh)
  • Generated client: src/frontend/src/client/ via @hey-api/openapi-ts

Regenerate the API client (backend must be running):

./scripts/generate_openapi_client.sh

This uses src/frontend/openapi-ts.config.ts to emit types, a fetch client, Zod schemas, and react-query hooks.

Testing & Quality ✅

  • Backend tests: uv run pytest -q (add --cov=backend for coverage)
  • Lint (Python): uv run ruff check .
  • Format (Python): uv run ruff format .
  • Frontend lint: from src/frontend/ run npm run lint

About

Fast, lightweight job scheduler with a modern UI

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors