todo application written as a celilo module
  • TypeScript 94.7%
  • JavaScript 2%
  • CSS 1.8%
  • Shell 0.5%
  • Go Template 0.4%
  • Other 0.6%
Find a file
Peter Banka 600ec9b0f8
All checks were successful
release / version (push) Successful in 8s
release / publish (push) Successful in 1m14s
Merge pull request 'chore: version lunacycle' (#40) from changeset-release/main into main
Reviewed-on: #40
2026-08-02 23:58:18 +00:00
.changeset chore: version lunacycle 2026-08-02 23:57:33 +00:00
.cspell Make the task edit dialog take the full screen on mobile 2025-06-12 16:52:33 -07:00
.forgejo/workflows chore: goals changeset + make the CI changeset check a blocking gate 2026-08-02 00:54:27 -07:00
apps fix(cycle-dates): cycle boundaries are full moons, not new moons 2026-08-02 16:27:38 -07:00
celilo fix(cd): document the upgrade_policy half of CD, and run the hook tests in CI 2026-08-01 16:50:23 -07:00
deploy Add multi-day calendar numbering 2026-04-11 09:39:23 -07:00
designs design(goals): agreed design + openspec change for first-class goals 2026-08-01 22:10:22 -07:00
docs Add task scheduling e2e test, testing docs, and fix reseed reliability 2026-04-04 20:35:38 -07:00
e2e e2e: reproduce + gate ISS-0101 (split-horizon www resolves to natIp) 2026-06-13 20:52:12 -07:00
openspec fix(cycle-dates): cycle boundaries are full moons, not new moons 2026-08-02 16:27:38 -07:00
packages fix(cycle-dates): cycle boundaries are full moons, not new moons 2026-08-02 16:27:38 -07:00
plans Rename conductor -> celilo throughout lunacycle 2026-04-14 11:57:29 -07:00
public Update favicon 2025-05-19 17:55:27 -07:00
scripts fix(dev): point vite at the backend origin in dev.bun.ts 2026-08-01 22:10:22 -07:00
tests fix(cycle-dates): cycle boundaries are full moons, not new moons 2026-08-02 16:27:38 -07:00
.envrc Add multi-day calendar numbering 2026-04-11 09:39:23 -07:00
.gitignore 🐛 Clean up mobile delivery 2026-05-06 21:28:26 -07:00
.mise.toml ci: node-via-mise (git-native checkout) — match celilo runner pattern 2026-06-21 12:40:51 -07:00
.prettierignore Migrate to NX monorepo with apps/packages structure 2026-03-29 19:50:32 -07:00
.prettierrc Migrate to NX monorepo with apps/packages structure 2026-03-29 19:50:32 -07:00
AUTHENTIK_CONDUCTOR_INTEGRATION.md Rename conductor -> celilo throughout lunacycle 2026-04-14 11:57:29 -07:00
bun.lock fix(publish): drop better-sqlite3 + dead 0008 backfill; --ignore-scripts on build 2026-06-26 11:38:02 -07:00
CHANGELOG.md chore: version lunacycle 2026-08-02 23:57:33 +00:00
CLAUDE.md docs: replace CLAUDE.md with psbanka TypeScript engineering standards 2026-08-01 22:13:37 -07:00
components.json Use tech stack vite_react_shadcn_ts 2025-03-31 04:58:45 +00:00
ecosystem.config.js Add ecosystem file for pm2 startup 2025-08-13 20:56:45 -07:00
env-example instrument server 2025-04-17 21:58:35 -07:00
eslint.config.js Use tech stack vite_react_shadcn_ts 2025-03-31 04:58:45 +00:00
eslint.config.mjs Add backup/restore hooks, dual dev modes, fix auth UX and lint errors 2026-04-07 13:21:17 -07:00
KNOWN_TEST_FAILURES.md fix(cycle-dates): cycle boundaries are full moons, not new moons 2026-08-02 16:27:38 -07:00
manifest.yml chore: version lunacycle 2026-08-02 23:57:33 +00:00
mise.toml Render backlog with atoms 2025-11-27 12:41:22 -08:00
nx.json clean up build and claude-files 2026-05-03 00:20:14 -07:00
package.json fix(seed): address seeded rows by their generated uuid, not by title 2026-08-01 21:06:07 -07:00
playwright.config.ts test(e2e): set VITE_BACKEND_ORIGIN in the web webServer (CI fix) 2026-06-26 07:41:49 -07:00
README.md Fix health-check hook API; PKCE auth flow; use published @celilo/e2e@0.6.0 2026-04-20 14:54:15 -07:00
tsconfig.base.json chore(deps): bump framework deps (React 19, zod 4, TS 6, eslint 10, etc.) + fix lint 2026-06-14 15:14:13 -07:00
tsconfig.json Remove stale pre-migration files and fix imports to NX structure 2026-04-01 11:01:21 -07:00
tsconfig.node.json Lots of functionality and sanity 2025-04-12 19:48:28 -07:00
vitest.config.ts fix(test): resolve workspace alias in vitest + pass secrets to health-check tests 2026-06-14 15:17:46 -07:00

LunaCycle

Family task management with lunar rhythm integration. Deploys as a Bun API server with a React frontend, served through Caddy, authenticated via Authentik OIDC.

Development

bun install
bun run dev          # web + server in parallel
bun run test:unit    # unit tests

Building a Release Package (.netapp)

LunaCycle is deployed via Celilo as a .netapp module package.

bun run netapp

This runs celilo package . --output lunacycle.netapp, which:

  1. Stages source via bun pm pack (respecting the files field in package.json)
  2. Runs the full build: bun install && bun run build
  3. Packages artifacts + Celilo module files into lunacycle.netapp

When to rebuild: Any time you change server code, client code, Ansible roles, or Celilo hook scripts.

You do NOT need to rebuild the standard module netapps (namecheap, greenwave, iptables, caddy, authentik) — those are managed by the infra repo and baked into the @celilo/e2e Docker image.

E2E Deployment Tests

Tests run in a simulated Docker network (DNS, firewalls, ACME server, target machines) provided by @celilo/e2e.

Prerequisites

  • Colima running: colima start
  • Docker images built (once per machine, or after infra changes):
cele2e build

This packages the standard Celilo modules and bakes them into the management Docker image. Only needed again if you update @celilo/e2e or the infra repo's standard modules.

Running Tests

Fresh run (builds full network from scratch, ~10 min):

bun run netapp
cele2e run --keep deploy

Fast iteration (reuses existing network, ~2-3 min):

bun run netapp
cele2e run --keep --reuse deploy

Check if a reusable network exists:

cele2e status

Tear down when done:

cele2e down

What the deploy test covers

  1. Buildlunacycle.netapp exists (fail fast if you forgot bun run netapp)
  2. Prerequisites — deploys the full supporting stack into the simulated network:
    • namecheap (DNS registrar)
    • greenwave + iptables (firewalls)
    • caddy (reverse proxy / TLS)
    • authentik (identity provider)
  3. Lunacycle deployment — Ansible installs binary + systemd service
  4. Infrastructure checks — binary present, service running, Caddy routes registered, static assets uploaded
  5. Authentication flow — full PKCE login:
    • config.js has resolved URLs (catches $self:primary_domain regressions)
    • Authentik has the lunacycle-web OIDC client registered
    • Test user lunacycle_admin exists
    • Complete authorization code → token exchange → protected API call

Default test credentials

Field Value
Username lunacycle_admin
Password lunacycle-rules
Domain iamtheinternet.org (simulated)
Caddy https://www.iamtheinternet.org
Authentik https://auth.iamtheinternet.org

These are e2e-only test credentials — not used in production.

Updating the standard module images

If you change something in the infra repo's standard modules (caddy, authentik, etc.) and need to test it:

cd ~/hobby/infra/packages/e2e
cele2e build          # rebuilds all images with updated netapps

Or publish a new @celilo/e2e version from infra and pnpm install here.

Celilo Module Structure

manifest.yml              — Celilo module manifest
celilo/
  scripts/
    setup-web.ts          — on_install: registers Caddy routes, uploads assets, registers OIDC client
    health-check.ts       — health_check: SSH checks on the deployed container
    backup.ts             — on_backup: database backup
    restore.ts            — on_restore: database restore
  terraform/
    main.tf.tpl           — LXC container definition
    outputs.tf.tpl        — Terraform outputs
  ansible/
    playbook.yml.tpl      — Ansible playbook
    roles/lunacycle/      — Server install + migration roles
e2e/
  tests/deploy.test.ts    — Deployment + auth integration tests

Production Deployment

Deployed and managed via Celilo on the home lab. See the infra repo for architecture details.

# On the ops machine:
celilo module deploy lunacycle