Commit Graph

15 Commits

Author SHA1 Message Date
giles
eed5aff238 Add healthcheck and start-first update for l2-server
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m7s
Zero-downtime deploys: new container starts and passes health
check before the old one is stopped. Caddy always has a healthy
backend to proxy to.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 22:20:00 +00:00
giles
859ff0b835 Eliminate ${VAR} substitutions from docker-compose.yml
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m41s
Move DATABASE_URL and POSTGRES_PASSWORD to .env via env_file.
docker stack deploy no longer needs env vars sourced, and
repeat deploys won't trigger spurious restarts.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 22:06:40 +00:00
gilesb
fbf188afdc Remove hardcoded secrets from public repo
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m3s
- Remove default password fallback from POSTGRES_PASSWORD in docker-compose.yml
- Remove default password fallback from db.py and migrate.py
- Update .env.example with required POSTGRES_PASSWORD
- Update README to mark DATABASE_URL as required

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 19:29:24 +00:00
giles
8f1ba74c53 Add Gitea Actions CI/CD and use private registry
Some checks failed
Build and Deploy / build-and-deploy (push) Failing after 12s
Add CI workflow mirroring celery pipeline: SSH to deploy server,
git pull, build and push to registry, deploy docker stack.
Update docker-compose to pull l2-server from registry.rose-ash.com:5000.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 19:23:22 +00:00
gilesb
2267096271 Add format_date helper to handle datetime objects in templates
The db now returns datetime objects instead of strings in some cases.
Added format_date() helper function that handles both datetime and string
values, and replaced all [:10] date slicing with calls to this helper.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-09 01:20:32 +00:00
gilesb
5ef65bac14 Expose IPFS swarm port 4002 for P2P connectivity
Uses port 4002 externally (L1 uses 4001) to avoid conflict
when both run on same server.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 18:51:41 +00:00
gilesb
1e134e0f6e Add externalnet to IPFS for gateway access
Allows nginx to proxy to L2 IPFS gateway at ipfs.artdag.rose-ash.com

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 18:44:33 +00:00
gilesb
96631e1e4c Add IPFS node to L2 for federated content storage
- Add IPFS container to docker-compose
- Add ipfshttpclient dependency
- Add ipfs_client.py module for IPFS operations
- Add ipfs_cid field to Asset model and database schema
- Pin content on L2 IPFS when assets are published/registered

L2 now stores content on its own IPFS node, enabling
federation - content remains available even if L1 goes down.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 18:21:33 +00:00
gilesb
82cb1cf711 Fix logout to clear both legacy and shared domain cookies
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 17:38:14 +00:00
gilesb
9c10de7534 Fix Swarm compatibility, add legacy /registry/record-run route
- Fix depends_on syntax for Docker Swarm (simple list, not extended)
- Add /registry/record-run as legacy alias for /assets/record-run

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 00:33:59 +00:00
gilesb
a6e83c72bd Migrate to PostgreSQL database, consolidate routes, improve home page
- Add PostgreSQL with asyncpg for persistent storage
- Create db.py module with async database operations
- Create migrate.py script to migrate JSON data to PostgreSQL
- Update docker-compose.yml with PostgreSQL service
- Home page now shows README with styled headings
- Remove /ui prefix routes, use content negotiation on main routes
- Add /activities/{idx} as canonical route (with /activity redirect)
- Update /assets/{name} to support HTML and JSON responses
- Convert auth.py to use async database operations
- RSA keys still stored as files in $ARTDAG_DATA/keys/

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 00:22:21 +00:00
gilesb
8159627651 fix: use env_file for all server config
- Move ARTDAG_DOMAIN, ARTDAG_USER, ARTDAG_L1, JWT_SECRET to .env
- Update docker-stack.yml L1 config to use env_file
- Add .env.example with all required variables

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-07 19:31:02 +00:00
giles
51c86878af feat: add JWT secret via env_file, gitignore .env 2026-01-07 15:41:59 +00:00
giles
acaf3a0ffa refactor: standalone docker-compose for L2 activitypub stack 2026-01-07 13:39:19 +00:00
gilesb
be23488204 feat: Docker support for L2 server
- Dockerfile for L2 ActivityPub server
- docker-compose.yml for standalone L2
- docker-stack.yml for full swarm deployment (L1+L2+Redis)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-07 12:04:58 +00:00