Commit Graph
32 Commits
Author SHA1 Message Date
Asep Haryana b5596e1398 feat(infra): full Nix migration — all 6 services + CI/CD
- flake.nix: 6 derivations (hub, scraper, tools-gateway, tools-workers, tools-frontend, llm-api)
- Fetch submodule source via builtins.fetchGit with pinned revs
- Fix cargo HOME/TMPDIR for Nix sandbox permission issues
- Fix llm-api: CMake/Clang deps for llama.cpp-sys2 bindgen
- Add LIBCLANG_PATH, LD_LIBRARY_PATH for Rust bindgen builds
- Systemd units: tools-gateway (3501), tools-frontend (3500), tools-workers, llm-api (8080)
- tools.target for grouped management
- Env configs: /etc/tools/env, /etc/llm-api/env
- GitHub Actions: nix-build.yml — matrix build + nix copy + deploy
- Update Traefik apps.yaml: tools/host.docker.internal:3500, llm-api/host.docker.internal:8080
- iptables: allow Docker→host on 3099, 4091, 3500, 3501, 8080
- Add scripts/nix-deploy.sh for CI/CD deploy step
2026-07-30 19:45:43 +07:00
Asep Haryana 46730ec07d feat(infra): Nix build for scraper, GitHub Actions workflow
- Build scraper (Rust) with Nix — cargo build --release
- Create scraper systemd unit (port 4091), env from Docker config
- Fix HOME/CARGO_HOME for Rust/cargo in Nix sandbox
- Update Traefik apps.yaml: scraper -> host.docker.internal:4091
- Add iptables rules for port 4091 (Docker->host)
- Add GitHub Actions workflow: nix-build.yml (determinate-nix + deploy)
- Save iptables rules persistently
2026-07-30 18:46:45 +07:00
asepharyana 18cabefe9c fix(ci): remove duplicate submodule sync code in docker-build-push
The Sync submodule locally step had an identical duplicate block: after
cd-ing into SUBNODULE_PATH in the first block, the second block tried
cd SUBNODULE_PATH again, causing 'No such file or directory' since
the working directory was already inside the submodule path.

Also added cd $GITHUB_WORKSPACE at the end of the first block to
ensure the next step starts from the workspace root.
2026-07-25 18:58:59 +07:00
asepharyana 3dfde5e872 fix(ci): add tools to allowed services in update-submodule workflow 2026-07-25 16:39:38 +07:00
asepharyana 95a9921b7a fix(deploy): use 'docker compose config --services' for reliable service name extraction
Replace fragile grep-based extraction that matched volume names
(nats_data, tools_data) and 'null' as pseudo-services.
2026-07-25 14:21:48 +07:00
asepharyana e953c3cb67 ci(llm-api): integrate into hub CI/CD pipeline
- Add llm-api to docker-build-push workflow (build, push, deploy)
- Add llm-api compose file to deploy-docker ALL_COMPOSE_FILES
- Add llm-api to update-submodule workflow
- Add llm-api CodeQL build step in security workflow
- Fix typo in Traefik host rule (asepharya -> asepharyana)
- Update CLAUDE.md submodule list
- Fix .gitmodules URL for llm-api submodule
- Clean up standalone infra files from llm-api submodule repo
2026-07-25 13:39:35 +07:00
asepharyanaandKilo c8fcaecbdb fix(ci): make tools submodule public for CI access
Tools repo is now public so GITHUB_TOKEN can clone it.
Revert the token injection workaround since it's no longer needed.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:16:21 +07:00
asepharyanaandKilo 67288c8723 feat(infra): add tools service with document scanner, image & PDF tools
Implement self-hosted document scanner and media processing tools as
an alternative to CamScanner/ilovepdf without third-party uploads.

Backend: Rust Axum gateway + worker pool with NATS JetStream queue
Frontend: Next.js 16 + shadcn/ui + Tailwind v4 + Framer Motion
Pipeline: Canny edge detection -> DLT homography warp -> Sauvola
binarization -> Hough deskew -> Tesseract OCR -> searchable PDF

Phase 1 (MVP) delivers:
- Document scanner with perspective correction and OCR
- Image compress/resize/convert tools
- PDF merge/split/compress tools
- Real-time WebSocket progress updates
- Rate limiting, auto-cleanup, Prometheus metrics
- Full CI/CD pipeline with Docker multi-stage build

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:08:09 +07:00
dependabot[bot]andGitHub 0242fc4b68 chore(deps): bump actions/checkout
Bumps the github-actions group with 1 update in the / directory: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 6 to 7
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-07-23 18:39:01 +00:00
Asepharyana b7e4203a15 fix(security): checkout git submodules for CodeQL Rust analysis 2026-07-24 01:36:17 +07:00
asepharyanaandAsep Haryana Saputra 93d053b123 ci(deploy): remove :latest tag from Docker images to avoid cache bugs
Using only :sha-<short> tags ensures deterministic image references
and prevents stale :latest caches from serving wrong images.

Co-Authored-By: Asep Haryana Saputra <asepharyana@users.noreply.github.com>
2026-07-23 18:15:17 +07:00
asepharyanaandClaude Opus 4.8 aaaf5de70c feat(infra): remove Go dashboard, dashboard is now part of hub Next.js app
- Remove dashboard container from observability.yml
- Remove infra/docker/dashboard.Dockerfile
- Remove dashboard route from Traefik apps.yaml
- Mount Docker socket on hub container for /api/dashboard
- Remove dashboard build from CI/CD (docker-build-push.yml)
- Update submodule pointer to hub with Next.js dashboard rewrite

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 07:23:12 +07:00
asepharyana cea96fcfc2 fix(ci): update dashboard detection to apps/hub/dashboard/ 2026-07-23 07:19:55 +07:00
asepharyanaandClaude Opus 4.8 9db886e68b feat(infra): add hub service — Docker, Traefik, CI/CD
- Add infra/docker/hub.Dockerfile (Next.js multi-stage build)
- Add infra/compose/hub.yml with app-shared-net
- Add Traefik route for hub.asepharyana.{my,web}.id → hub:3000
- Update docker-build-push.yml: path detection, matrix build, dispatch, manifest
- Update deploy-docker.yml: include hub.yml in ALL_COMPOSE_FILES
- Update update-submodule.yml: allow hub service
- Update docs/ARCHITECTURE.md

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 07:19:55 +07:00
asepharyana 6c24508c77 fix(ci): add missing dashboard output in changes job so update-manifest runs 2026-07-23 05:20:59 +07:00
asepharyana aa05820393 fix(ci): correct dashboard change detection regex to match files inside infra/dashboard/ 2026-07-23 05:16:47 +07:00
asepharyana 4ef4f615c1 feat: add dashboard service to Docker build and push workflow 2026-07-22 18:12:44 +07:00
asepharyana dcb93035f3 feat(observability): add OpenTelemetry Collector, Jaeger, and custom dashboard for monitoring
fix(infra): update NATS configuration for OpenTelemetry tracing and JetStream support
refactor(dapr): modify Dapr sidecar configuration to use new resources path and config file
chore(docs): update deployment documentation to include observability services
docs(commit-convention): establish commit message guidelines for Asepharyana Hub
docs(deploy-workflow): outline CI/CD pipeline and manual deployment steps for Asepharyana Hub
feat(event-driven): implement event-driven architecture patterns with Dapr and NATS
docs(hub-rules): define repository structure, submodule strategy, and infrastructure patterns
2026-07-22 16:43:37 +07:00
asepharyana 64b8bb29a3 fix: include all compose files for dependency resolution on selective deploy
Scraper services depend on dapr-placement (dapr.yml) and nats (nats.yml).
When only scraper.yml changed, docker compose pull/up failed with
'undefined service' because dependent compose files were excluded.

Now always include ALL compose files for dependency resolution, but
selectively pull and up only the target services during partial updates.
2026-07-22 08:40:49 +07:00
asepharyana 79015974df fix: map scraper-api service name to correct submodule path
The update-submodule.yml workflow used apps/${SERVICE} directly,
but the submodule path is apps/scraper, not apps/scraper-api.
Added a case statement to map service names to correct paths.
2026-07-22 07:17:40 +07:00
asepharyana a6b822bbfe fix: add manual cargo build step for CodeQL Rust analysis
The security.yml CodeQL job fails because:
1. The Rust project is in apps/scraper/, not at the repo root
2. CodeQL v4's autobuilder can't find Cargo.toml at the root
3. CodeQL v4 requires the Rust code to be built for analysis

Also removes javascript-typescript language since this repo has no JS/TS code.
2026-07-22 07:02:25 +07:00
asepharyana 0ba5da78f9 fix: remove javascript-typescript from CodeQL languages in security.yml
The repo only has Rust source code (no JS/TS). CodeQL v4 fails when
a specified language has no code to analyze, which blocks PR #5
(dependabot bumping codeql-action from v3 to v4).
2026-07-22 06:59:17 +07:00
asepharyanaandClaude Opus 4.8 ea168b4b20 feat: add NATS + Dapr infrastructure for event-driven architecture
- infra/compose/nats.yml: NATS server with JetStream, persistence volume, healthcheck
- infra/compose/dapr.yml: Dapr placement service for sidecar coordination
- infra/dapr/: Dapr global config, pubsub component (NATS), statestore (Redis)
- infra/compose/scraper.yml: add Dapr sidecar container + depends_on nats/dapr
- docs/add-dapr-service.md: guide for integrating Dapr into new services
- docs/add-new-app.md: add Dapr sidecar step
- ARCHITECTURE.md: add NATS/Dapr to infra table + service mesh diagram
- infra/README.md: update layout and deployment order
- deploy-docker.yml: add nats.yml + dapr.yml to ALL_COMPOSE_FILES

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-21 17:26:02 +07:00
asepharyana 092c0b363d Refactor Dockerfile for scraper, update Traefik configuration, and clean up scripts
- Simplified Dockerfile for scraper by removing unnecessary Node.js installation and optimizing build stages.
- Updated Traefik environment configuration to use shorter variable names for certificate paths.
- Removed commented-out middleware configurations in dynamic middlewares.yaml.
- Cleaned up legacy SSL configurations in ssl.yaml.
- Disabled insecure API access in Traefik configuration.
- Deleted unused renovate.json file.
- Modified update environment script to only process apps directory.
- Updated GHCR cleanup script to target specific package.
- Streamlined dependency update script to focus on app submodules.
- Removed setup script for Prometheus as it is no longer needed.
2026-07-21 13:27:13 +07:00
asepharyana cdad9ae720 chore: remove unused configuration files and submodules 2026-07-21 12:54:57 +07:00
asepharyana ef7e708fd6 fix: revert deploy workflow, secrets already configured 2026-07-10 07:16:16 +07:00
asepharyana 9a003436b4 fix: skip deploy workflow when SSH secrets not configured 2026-07-10 07:14:17 +07:00
asepharyana 4b37c3d27a ci: add workflow_dispatch trigger to Lint workflow 2026-07-10 06:25:08 +07:00
asephsandClaude Opus 4.8 003083ca78 refactor: standardize typecheck script across submodules
- apps/react: split tsc from build, add typecheck script
- apps/elysia: rename check-types to typecheck
- CI: update elysia typecheck command
- Update submodule pointers

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 06:07:18 +07:00
asephsandClaude Opus 4.8 76ccc5ffe9 chore: migrate from ESLint/Prettier to Biome
- Add biome.json with recommended preset + custom rules
- Remove eslint.config.mjs (root, apps/react, apps/elysia)
- Remove .prettierrc and .prettierignore
- Update package.json: remove eslint/prettier deps, add biome scripts
- Update Makefile: lint/format targets to biome
- Update CI (lint.yml): eslint -> biome ci
- Update VSCode config: biomejs.biome extension + default formatter
- Apply biome format --write to all files
- Update submodule pointers for react and elysia

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 05:42:53 +07:00
asephsandClaude Opus 4.8 b199f8ce9d fix: GH Actions workflows - enforce lint/typecheck, add timeout, fix triggers
- lint.yml: remove || echo so lint errors actually fail the workflow
- typecheck.yml: remove || echo, switch to Bun, add apps/elysia typecheck
- update-submodule.yml: upgrade checkout@v6, add payload validation + push retry
- security.yml: add Rust to CodeQL scan targets
- docker-build-push.yml: remove stale packages/ path refs
- All workflows: add timeout-minutes to prevent stuck jobs

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-10 02:06:27 +07:00
asepharyana b31fe9d188 chore: initial hub repo structure 2026-07-09 22:08:26 +07:00