No description
Find a file
2026-04-26 16:45:07 +02:00
.forgejo/workflows 1 - Add production Dockerfile 2026-04-23 19:55:57 +02:00
app 12 - Add crawler config and FetchResult value object 2026-04-26 16:45:07 +02:00
bootstrap 5 - Trust forwarded headers behind reverse proxy for real client IP 2026-04-26 11:56:39 +02:00
config 5 - Publish Livewire config with class-based components and no emoji 2026-04-26 11:54:23 +02:00
database 7 - Add page_crawls migration, PageCrawl model, factory, and Page relationships 2026-04-26 14:15:49 +02:00
docker 1 - Add production Dockerfile 2026-04-23 19:55:57 +02:00
packages/Lvl0/FediDiscover 3 - Harden fediverse polling: timeouts, error handling, payload fields 2026-04-26 01:15:35 +02:00
public chore - Set Pint concat_space to spaced + reformat 2026-04-23 23:02:50 +02:00
resources 5 - Add UrlSubmissionForm Livewire component with rate limiting 2026-04-26 11:58:51 +02:00
routes 5 - Add UrlSubmissionForm Livewire component with rate limiting 2026-04-26 11:58:51 +02:00
storage 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
tests 12 - Add crawler config and FetchResult value object 2026-04-26 16:45:07 +02:00
.dockerignore 1 - Add production Dockerfile 2026-04-23 19:55:57 +02:00
.editorconfig 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
.env.example 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
.gitattributes 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
.gitignore 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
.npmrc 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
artisan 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
composer.json 1 - Add Larastan static analysis + Package test suite 2026-04-23 18:01:24 +02:00
composer.lock 1 - Add Larastan static analysis + Package test suite 2026-04-23 18:01:24 +02:00
Dockerfile.dev 1 - Fix npm install skipped on first boot due to volume-mounted node_modules 2026-04-23 17:45:43 +02:00
LICENSE Initial commit 2026-04-23 01:27:34 +02:00
package-lock.json 1 - Fix npm install skipped on first boot due to volume-mounted node_modules 2026-04-23 17:45:43 +02:00
package.json 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00
phpstan.neon 1 - Add Larastan static analysis + Package test suite 2026-04-23 18:01:24 +02:00
phpunit.xml 4 - Add UrlDiscoveredListener wiring fediverse polling to pages graph 2026-04-26 03:31:32 +02:00
pint.json chore - Set Pint concat_space to spaced + reformat 2026-04-23 23:02:50 +02:00
README.md 1 - Add README with deployment docs 2026-04-23 20:12:05 +02:00
shell.nix 1 - Add Nix shell and Docker dev environment 2026-04-23 03:00:07 +02:00
vite.config.js 1 - Install Laravel 13 with Livewire 2026-04-23 03:13:33 +02:00

Trove

A federated search engine for the small web. Seeded by fediverse attention, ranked by domain coherence rather than commercial authority.

Tech stack

Laravel 13 · Livewire 4 · PostgreSQL 17 (tsvector FTS) · Redis 7 · FrankenPHP · Vite 8 · Tailwind 4.

Local development

Requires Nix and Podman.

nix-shell          # enter dev shell
dev-up             # start app, db, redis

App: http://localhost:8200 · Vite HMR: http://localhost:5175

Other helpers inside the nix shell: dev-down, dev-rebuild, dev-shell, dev-artisan <cmd>, dev-logs.

Self-hosting

Trove ships as a Docker image published to forge.lvl0.xyz/lvl0/trove. You provide the compose/stack config.

Required environment

Variable Purpose
APP_KEY Laravel app key. Generate with docker run --rm forge.lvl0.xyz/lvl0/trove:latest php artisan key:generate --show. Must persist across deployments or sessions/encrypted data break.
APP_URL Public URL, e.g. https://trove.example.org
DB_DATABASE, DB_USERNAME, DB_PASSWORD PostgreSQL credentials
DB_HOST Hostname of the PostgreSQL service. Default db. Override if your service is named differently.
REDIS_HOST Hostname of the Redis service. Default redis. Override if your service is named differently.

Services you need to provide

  • App: pull forge.lvl0.xyz/lvl0/trove:latest (or a pinned v* tag). Exposes port 8000 inside the container. The image runs migrations and warms caches on boot.
  • PostgreSQL 17. Hostname must be reachable as db (default) or set DB_HOST. Persist /var/lib/postgresql/data.
  • Redis 7 with --appendonly yes (queue jobs persist across restarts). Hostname redis or set REDIS_HOST.

On first boot the startup script waits for PostgreSQL, warms caches, then runs php artisan migrate --force automatically. The 60-second wait loop covers slow PG init; it exits with a clear error if PG never becomes reachable.

Volumes

  • /app/storage — Laravel writable paths (logs, cached views, uploads). Persist this.

Healthcheck

The image exposes GET /up (Laravel's built-in health route). The Dockerfile declares a HEALTHCHECK; your orchestrator can use curl -fsS http://localhost:8000/up for liveness.

Example compose stack

A minimal reference — adapt for your infra. DockGE, Portainer, docker compose, Kubernetes, and bare podman play kube all work with equivalent configs.

services:
  app:
    image: forge.lvl0.xyz/lvl0/trove:latest
    restart: always
    ports: ["${APP_PORT:-8400}:8000"]
    environment:
      APP_KEY: "${APP_KEY}"
      APP_URL: "${APP_URL}"
      DB_DATABASE: "${DB_DATABASE}"
      DB_USERNAME: "${DB_USERNAME}"
      DB_PASSWORD: "${DB_PASSWORD}"
    volumes:
      - app_storage:/app/storage
    depends_on:
      db: { condition: service_healthy }
      redis: { condition: service_healthy }

  db:
    image: postgres:17-alpine
    restart: always
    environment:
      POSTGRES_DB: "${DB_DATABASE}"
      POSTGRES_USER: "${DB_USERNAME}"
      POSTGRES_PASSWORD: "${DB_PASSWORD}"
    volumes:
      - db_data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"]
      interval: 10s
      retries: 5
      start_period: 10s

  redis:
    image: redis:7-alpine
    restart: always
    command: redis-server --appendonly yes
    volumes:
      - redis_data:/data
    healthcheck:
      test: ["CMD", "redis-cli", "ping"]
      interval: 10s
      retries: 5

volumes:
  db_data:
  redis_data:
  app_storage:

Upgrades

Pull the new image tag, recreate the app container. Migrations run on boot (php artisan migrate --force in the startup script). Rollback by pointing at the previous v* tag.


AGPL-3.0-or-later. See LICENSE.

Part of lvl0, a collective for horizontal FOSS projects.