Commit Graph
151 Commits
Author SHA1 Message Date
asepharyanaandKilo c25850b727 fix(infra): use unique binary names in Dockerfile builder stage
The cp destination /app/gateway conflicts with the source code
directory apps/tools/backend/gateway/ which is copied to /app/gateway/.
Use /app/tools-gateway-bin to avoid name collision.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 17:42:50 +07:00
asepharyanaandKilo 97b48ddb21 fix(infra): remove depends_on redis/nats from tools.yml
Shared services are in separate compose files. Tools depends on them
at runtime but Docker compose doesn't need to manage their lifecycle.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 17:40:35 +07:00
GitHub Action ab994ffd54 chore: update manifests and submodules [skip ci] 2026-07-24 07:17:21 +00:00
GitHub Action 9d0b075b92 chore: update manifests and submodules [skip ci] 2026-07-24 07:16:37 +00:00
asepharyanaandKilo c5a7ae247a fix(infra): copy binaries from builder's filesystem, not cache mount
The builder stage uses --mount=type=cache for /app/target, so binaries
are in the cache which isn't available to the runtime stage COPY.
Fix by copying from /app/gateway and /app/workers which were cp'd
to the builder's regular filesystem.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 14:10:13 +07:00
asepharyanaandKilo cbda54fdee fix(infra): update tools submodule to rust 1.89 toolchain
Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:57:51 +07:00
asepharyanaandKilo 836ef6862e fix(infra): bump cargo-chef image to rust 1.89 for compatibility
cargo-chef with rust 1.85 has compatibility issues with some dependency crates.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:45:51 +07:00
asepharyanaandKilo bd751c0fca fix(infra): update tools submodule to fix AbortController type error
Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:43:32 +07:00
asepharyanaandKilo ad7a0de37b fix(infra): update tools submodule to fix lucide icon imports
Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:41:07 +07:00
asepharyana 05a9179356 chore: update tools submodule to latest (add bun.lock) 2026-07-24 13:32:44 +07:00
asepharyanaandKilo 584a7155e6 fix(infra): use pre-built cargo-chef image in Dockerfile
Replace cargo install cargo-chef with pre-built image
lukemathwalker/cargo-chef:latest-rust-1.85.0 and add build
cache mounts for faster rebuilds.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:32:31 +07:00
asepharyanaandKilo a41b2d7312 fix(infra): remove bun.lock from Dockerfile, fix frontend build
The bun.lock doesn't exist yet - use bun install without frozen-lockfile.
This will be optimized once a lockfile is generated.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:20:30 +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 d8b1457a11 fix(infra): convert apps/tools to submodule, fix Dockerfile paths
Move tools code to its own repo (asepharyana/asepharyana-hub-tools)
and add as git submodule following the existing app pattern.
Fix Dockerfile paths to use apps/tools/ prefix since build context
is the repo root.

Co-Authored-By: Kilo <kilo@kilo.ai>
2026-07-24 13:11:54 +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
asepharyana 9c12d135e4 Implement code changes to enhance functionality and improve performance 2026-07-24 10:19:03 +07:00
asepharyana 68dea35d73 feat: add infrastructure documentation and processing pipeline for document scanner
- Introduced a comprehensive Docker image architecture for the project, detailing multi-stage builds for Rust backend and Next.js frontend.
- Added Docker Compose configuration for the tools service, including environment variables and volume management.
- Documented CI/CD integration steps for Docker build and deployment workflows.
- Implemented a detailed processing pipeline for document scanning, covering stages from image preprocessing to PDF generation.
- Included edge case handling and performance budget for each stage of the pipeline.
- Enhanced security considerations and rollback strategies for the tools service.
2026-07-24 10:19:03 +07:00
GitHub Action 447b22d9da chore: update manifests and submodules [skip ci] 2026-07-24 02:11:27 +00:00
mytheclipsebotreview[bot]andGitHub e38fe75d3c Auto-merge PR #6
chore(deps): bump actions/checkout from 6 to 7 in the github-actions group across 1 directory
2026-07-24 02:09:41 +00:00
asepharyana ddc4c58243 chore: update subproject commit for hub application 2026-07-24 08:26:03 +07:00
Asepharyana 1e10973c86 ci: trigger fresh run for updated security.yml 2026-07-24 01:39:57 +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
asepharyanaandClaude Opus 4.8 7181710aa7 chore: remove lidm routes from file config — now via Docker labels
Routing is handled by container labels (traefik.enable + router labels),
so file-level routes for lidm are no longer needed.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 19:19:30 +07:00
asepharyanaandClaude Opus 4.8 478a0f849f fix: use websecure + tls for lidm routes, same pattern as other services
Cloudflare Origin CA wildcard cert covers *.asepharyana.my.id,
so websecure entrypoint with tls works correctly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 19:07:22 +07:00
asepharyanaandClaude Opus 4.8 7fc863d611 feat: add lidm frontend and backend routes to traefik config
Add routers and services for lidm.asepharyana.my.id (→ lidm-frontend:3000)
and lidm-api.asepharyana.my.id (→ lidm-backend:3001) behind Traefik.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 19:02:13 +07:00
GitHub Action df7aaedfba chore: update manifests and submodules [skip ci] 2026-07-23 11:17:49 +00: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
asepharyana 401a26aea9 chore: update hub submodule to f3ddc62 2026-07-23 17:56:37 +07:00
asepharyana 0a4952ce7f chore: update hub submodule to 22cdc2e 2026-07-23 17:56:15 +07:00
asepharyana 23ba9c48fa chore: update hub submodule to e528b6a 2026-07-23 17:05:17 +07:00
asepharyana 7e92351f45 chore: update hub submodule to 4dbaba7 2026-07-23 15:54:01 +07:00
asepharyana 8e489b9f41 chore: update hub submodule to 6b725f3 2026-07-23 15:03:04 +07:00
asepharyana 0dbaf66743 chore: update hub submodule to e529e8c 2026-07-23 12:47:56 +07:00
asepharyana 6091d358e1 chore: update hub submodule to d94524b 2026-07-23 12:21:34 +07:00
asepharyanaandClaude Opus 4.8 c17f5f5b32 docs: update ARCHITECTURE.md and CLAUDE.md
- HTTP flow includes hub routes (/, /dashboard, /api/dashboard)
- Compose table adds hub.yml and observability.yml
- Prometheus auto-discovery section (Docker SD + labels)
- Traefik metrics query reference
- Docker socket access pattern (group_add: 988)
- Service registry table includes root domain, hub, jaeger
- CLAUDE.md monitoring section

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 11:11:30 +07:00
asepharyana 83b825b449 chore: bump hub submodule (latency metric fix) 2026-07-23 07:59:08 +07:00
asepharyana 48086de66b chore: bump hub submodule to f0bbd13 2026-07-23 07:52:41 +07:00
asepharyana 545397eb1f fix(infra): fix Prometheus Docker SD relabel + group_add 2026-07-23 07:50:20 +07:00
asepharyanaandClaude Opus 4.8 40e1a80f9f feat(infra): auto-discovery Prometheus + Traefik metrics
- Prometheus: add docker_sd_configs for auto-discovery via labels
- Prometheus: mount Docker socket for Docker SD
- Traefik: enable --metrics.prometheus with entrypoint/service labels
- Traefik: add prometheus.io/scrape=true label
- Observability: mount Docker socket for Prometheus container
- Bump hub submodule (Traefik metrics queries + sparkline charts)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 07:45:59 +07:00
asepharyana 688ac095f6 fix(infra): add group_add for docker socket access in hub 2026-07-23 07:35:58 +07:00
GitHub Action a4852f636a chore: update manifests and submodules [skip ci] 2026-07-23 00:33:56 +00:00
asepharyana 69cae1e73e fix(infra): chown .next dir in hub Dockerfile for runtime permissions 2026-07-23 07:32:59 +07:00
GitHub Action bd9cc1f4c7 chore: update manifests and submodules [skip ci] 2026-07-23 00:25:10 +00: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 5ff8f9224f feat(infra): migrate dashboard into hub submodule
- Move infra/dashboard/ → apps/hub/dashboard/ (hub submodule repo)
- Update dashboard.Dockerfile to COPY from apps/hub/dashboard/
- Update go module path

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 07:19:55 +07:00
asepharyana caf3f1d79b fix(infra): remove hub subdomain from Traefik rule 2026-07-23 07:19:55 +07:00
asepharyana 4e4ed101c5 fix(infra): hub at root domain asepharyana.my.id 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