{"id":50326543,"url":"https://github.com/saiththerobo/peertube-startos","last_synced_at":"2026-05-29T06:30:56.146Z","repository":{"id":360385249,"uuid":"1249856554","full_name":"saiththerobo/peertube-startos","owner":"saiththerobo","description":"PeerTube for StartOS — self-hosted video platform with PostgreSQL and Valkey","archived":false,"fork":false,"pushed_at":"2026-05-26T07:40:07.000Z","size":40,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-05-26T08:27:49.143Z","etag":null,"topics":["activitypub","peertube","self-hosted","startos","video"],"latest_commit_sha":null,"homepage":"https://joinpeertube.org","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saiththerobo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-05-26T05:08:47.000Z","updated_at":"2026-05-26T07:31:56.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/saiththerobo/peertube-startos","commit_stats":null,"previous_names":["saiththerobo/peertube-startos"],"tags_count":3,"template":false,"template_full_name":"Start9Labs/hello-world-startos","purl":"pkg:github/saiththerobo/peertube-startos","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saiththerobo%2Fpeertube-startos","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saiththerobo%2Fpeertube-startos/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saiththerobo%2Fpeertube-startos/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saiththerobo%2Fpeertube-startos/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saiththerobo","download_url":"https://codeload.github.com/saiththerobo/peertube-startos/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saiththerobo%2Fpeertube-startos/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33640627,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-29T02:00:06.066Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["activitypub","peertube","self-hosted","startos","video"],"created_at":"2026-05-29T06:30:55.915Z","updated_at":"2026-05-29T06:30:56.140Z","avatar_url":"https://github.com/saiththerobo.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"icon.svg\" alt=\"PeerTube Logo\" width=\"21%\"\u003e\n\u003c/p\u003e\n\n# PeerTube on StartOS\n\n\u003e **Upstream repo:** \u003chttps://github.com/Chocobozzz/PeerTube\u003e\n\nPeerTube is a free, open-source, and decentralized video platform powered by ActivityPub. This package runs PeerTube on StartOS with a PostgreSQL database and Valkey cache.\n\n---\n\n## Table of Contents\n\n- [Image and Container Runtime](#image-and-container-runtime)\n- [Volume and Data Layout](#volume-and-data-layout)\n- [Installation and First-Run Flow](#installation-and-first-run-flow)\n- [Configuration Management](#configuration-management)\n- [Network Access and Interfaces](#network-access-and-interfaces)\n- [Actions (StartOS UI)](#actions-startos-ui)\n- [Backups and Restore](#backups-and-restore)\n- [Health Checks](#health-checks)\n- [Dependencies](#dependencies)\n- [Limitations and Differences](#limitations-and-differences)\n- [What Is Unchanged from Upstream](#what-is-unchanged-from-upstream)\n- [Contributing](#contributing)\n- [Quick Reference for AI Consumers](#quick-reference-for-ai-consumers)\n\n---\n\n## Image and Container Runtime\n\n| Container  | Image                              | Architectures      |\n| ---------- | ---------------------------------- | ------------------ |\n| peertube   | `chocobozzz/peertube:v8.1.8`       | x86_64, aarch64    |\n| postgres   | `postgres:17-alpine`               | x86_64, aarch64    |\n| valkey     | `valkey/valkey:9-alpine`           | x86_64, aarch64    |\n\nAll three containers share the host network namespace. PeerTube communicates with PostgreSQL and Valkey over `localhost`.\n\n---\n\n## Volume and Data Layout\n\n| Volume | Container Mount     | Purpose                          |\n| ------ | ------------------- | -------------------------------- |\n| `main` | `/data` (peertube)  | Uploads, thumbnails, HLS streams |\n| `main` | `/config` (peertube)| Runtime config, local overrides  |\n| `db`   | `/var/lib/postgresql` (postgres) | PostgreSQL data |\n\n`store.json` (inside `main`) holds generated secrets (postgres password, PeerTube secret, admin password) and the user-selected primary URL.\n\n---\n\n## Installation and First-Run Flow\n\n1. **Install** — StartOS pulls all three images. `generateSecrets` runs on init and writes `postgresPassword` and `peertubeSecret` to `store.json`. `generateConfig` writes `local-production.json` with transcoding resolutions pre-configured (360p/480p/720p).\n2. **Critical task: Set Admin Password** — `watchCredentials` creates this task because `adminPassword` is not yet set. The user runs the **Set Admin Password** action, which generates a password, stores it in `store.json`, and displays it.\n3. **Primary URL (auto-set)** — `taskSetPrimaryUrl` tries to auto-select the `.local` LAN URL. If none is available, a critical task prompts the user to run **Set Primary URL**.\n4. **Service starts** — PostgreSQL initializes, Valkey starts, PeerTube starts with `PT_INITIAL_ROOT_PASSWORD` from `store.json`. On first boot PeerTube creates the `root` admin with that password.\n\n---\n\n## Configuration Management\n\nConfiguration is passed entirely through environment variables. There is no `production.yaml` managed by the package. Key variables:\n\n| Variable                    | Source                        |\n| --------------------------- | ----------------------------- |\n| `PEERTUBE_DB_HOSTNAME`      | `localhost` (hardcoded)       |\n| `PEERTUBE_DB_USERNAME`      | `peertube` (hardcoded)        |\n| `PEERTUBE_DB_PASSWORD`      | `store.postgresPassword`      |\n| `PEERTUBE_REDIS_HOSTNAME`   | `localhost` (hardcoded)       |\n| `PEERTUBE_SECRET`           | `store.peertubeSecret`        |\n| `PT_INITIAL_ROOT_PASSWORD`  | `store.adminPassword`         |\n| `PEERTUBE_WEBSERVER_HOSTNAME` | parsed from `store.primaryUrl` |\n| `PEERTUBE_WEBSERVER_PORT`   | parsed from `store.primaryUrl` |\n| `PEERTUBE_WEBSERVER_HTTPS`  | parsed from `store.primaryUrl` |\n| `PEERTUBE_TRUST_PROXY`     | `[\"loopback\",\"uniquelocal\"]` (hardcoded) |\n\n`PT_INITIAL_ROOT_PASSWORD` is only applied by PeerTube on the very first database initialization. After that it is ignored. Rotating the admin password requires PeerTube's web interface.\n\n---\n\n## Network Access and Interfaces\n\n| Interface | Port | Protocol | Purpose                  |\n| --------- | ---- | -------- | ------------------------ |\n| Web UI    | 9000 | HTTP     | PeerTube web application |\n\n---\n\n## Actions (StartOS UI)\n\n| Action              | Visibility | Allowed When | Description                                                        |\n| ------------------- | ---------- | ------------ | ------------------------------------------------------------------ |\n| Set Admin Password  | Enabled    | Any          | Shows stored root credentials. Generates on first call.            |\n| Set Primary URL     | Enabled    | Any          | Pick which hostname PeerTube uses for video links and federation.  |\n\n---\n\n## Backups and Restore\n\n**Included in backup:**\n\n- PostgreSQL database (`pg_dump` via `sdk.Backups.withPgDump()`)\n- `main` volume (uploads, config, store.json)\n\n**Restore behavior:** pg_dump is restored into a fresh PostgreSQL instance. The `main` volume is restored in full including `store.json` (secrets carry over).\n\n---\n\n## Health Checks\n\n| Check          | Method                | Daemon     |\n| -------------- | --------------------- | ---------- |\n| PostgreSQL     | `pg_isready -U peertube` | postgres |\n| Valkey         | `valkey-cli ping`     | valkey     |\n| Web Interface  | Port listening (9000) | peertube   |\n\nThe postgres and valkey checks are internal (`display: null`) and are only used for startup ordering. Only the Web Interface check is shown to the user.\n\n---\n\n## Dependencies\n\nNone. PostgreSQL and Valkey run as sidecars within this package.\n\n---\n\n## Limitations and Differences\n\n1. **RTMP live streaming not exposed** — PeerTube supports RTMP on port 1935 for live streaming ingest, but StartOS does not currently support raw TCP port exposure. Live streaming via browser-based WebRTC still works.\n2. **Admin password rotation** — `PT_INITIAL_ROOT_PASSWORD` only applies on first DB init. Rotate via PeerTube's web interface (Admin → Users → root → Change password).\n3. **SMTP not pre-configured** — Configure email via PeerTube's admin panel (Admin → Configuration → Email).\n4. **No riscv64 support** — The upstream `chocobozzz/peertube` image is not published for riscv64.\n\n---\n\n## What Is Unchanged from Upstream\n\nThe PeerTube container image is used unmodified (`chocobozzz/peertube:v8.1.8`). No patches are applied. All configuration is injected via environment variables.\n\n---\n\n## Contributing\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md) for build instructions and development workflow.\n\n---\n\n## Quick Reference for AI Consumers\n\n```yaml\npackage_id: peertube\ncontainers:\n  peertube:\n    image: chocobozzz/peertube:v8.1.8\n    mounts:\n      - main/data -\u003e /data\n      - main/config -\u003e /config\n  postgres:\n    image: postgres:17-alpine\n    mounts:\n      - db -\u003e /var/lib/postgresql\n  valkey:\n    image: valkey/valkey:9-alpine\narchitectures: [x86_64, aarch64]\nports:\n  ui: 9000\ndependencies: none (postgres and valkey are sidecars)\nstore_json_keys:\n  adminPassword: root account password (generated by setAdminPassword action)\n  postgresPassword: internal postgres auth (generated on install)\n  peertubeSecret: JWT/session secret (generated on install)\n  primaryUrl: external URL for video links and federation\nactions:\n  set-admin-password: show/first-set root credentials\n  set-primary-url: pick external URL\ncritical_tasks:\n  - set-admin-password: blocks startup until admin password is set\n  - set-primary-url: fires only if stored URL becomes unavailable\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaiththerobo%2Fpeertube-startos","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaiththerobo%2Fpeertube-startos","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaiththerobo%2Fpeertube-startos/lists"}