diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 37b7ae55..e0ae749b 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -28,3 +28,23 @@ jobs: - name: Test run: pnpm test + + publish-packages: + name: Publish @bytelyst/* to Gitea npm registry + runs-on: ubuntu-latest + needs: [build-and-test] + timeout-minutes: 10 + defaults: + run: + working-directory: /Users/sd9235/code/mygh/learning_ai_common_plat + steps: + - name: Pull latest + run: git pull --ff-only origin main || true + + - name: Build all packages + run: pnpm -r --filter './packages/**' build + + - name: Publish to local Gitea registry + env: + GITEA_NPM_TOKEN: ${{ secrets.GITEA_NPM_TOKEN }} + run: bash ./scripts/publish-local-gitea-packages.sh diff --git a/docs/devops/GITEA_NPM_REGISTRY_MIGRATION.md b/docs/devops/GITEA_NPM_REGISTRY_MIGRATION.md index b73b5370..5809dc36 100644 --- a/docs/devops/GITEA_NPM_REGISTRY_MIGRATION.md +++ b/docs/devops/GITEA_NPM_REGISTRY_MIGRATION.md @@ -132,15 +132,15 @@ That is enough to treat this Mac as the single-VM rehearsal environment. - shared packages build cleanly in `learning_ai_common_plat` - a local-only Gitea package token was created and used successfully for local package publishing -- **49 `@bytelyst/*` packages** published to local Gitea npm registry +- **56 `@bytelyst/*` packages** published to local Gitea npm registry - a clean scratch `pnpm install` from the local Gitea registry works on all migrated repos - **all 10 product repos migrated** from `file:` refs + `docker-prep.sh` to semver `^0.1.0` + registry-backed Dockerfiles - all migrated repos pass host-side `pnpm install` and backend typecheck - Docker builds (backend + web) verified for all repos with Dockerfiles -- local Gitea CI green for 8/8 repos with CI workflows (FlowMonk, NoteLett, ActionTrail, LocalMemGPT, NomGap, ChronoMind, JarvisJr, PeakPulse) +- local Gitea CI green for 10/10 repos with CI workflows (FlowMonk, NoteLett, ActionTrail, LocalMemGPT, NomGap, ChronoMind, JarvisJr, PeakPulse, MindLyst, LysnrAI) - `docker-prep.sh` removed from all 10 repos - `GITEA_NPM_TOKEN` added to act_runner config for CI registry access -- stale "Build @bytelyst/* packages" step removed from all CI workflows +- stale "Build @bytelyst/\* packages" step removed from all CI workflows ### Important implementation finding @@ -170,9 +170,9 @@ Host-side installs, Docker builds, and local CI are all validated. | Topology | `NETWORK=` | Gitea host | Docker reaches Gitea via | `--add-host` needed? | | ------------------- | ---------- | ------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------- | -| **Local dev (Mac)** | `corp` | `localhost:3300` (GITEA_NPM_HOST=localhost) | `host.docker.internal` + `--add-host localhost:host-gateway` | **Yes** — expected | +| **Local dev (Mac)** | `corp` | `localhost:3300` (GITEA_NPM_HOST=localhost) | `host.docker.internal` + `--add-host localhost:host-gateway` | **Yes** — expected | | **Local dev (Mac)** | `home` | `:3300` (from `~/.gitea_vm_host`) | Direct internet (no proxy) | **No** — direct connection | -| **VM deployment** | N/A | `localhost:3300` or compose service `gitea:3300` | Native Docker networking | **No** — `ROOT_URL` resolves natively | +| **VM deployment** | N/A | `localhost:3300` or compose service `gitea:3300` | Native Docker networking | **No** — `ROOT_URL` resolves natively | The `--add-host localhost:host-gateway` workaround is the **correct local-dev pattern** when `NETWORK=corp`, not a generic blocker. On a VM, Gitea's `ROOT_URL` will be set to the real hostname or compose service name, so tarball URLs resolve without any host-mapping workaround. @@ -180,8 +180,8 @@ At the time of writing (2026-03-24): - host-side registry usage is validated across all 10 migrated repos - Docker builds verified for all repos with Dockerfiles -- local Gitea CI green for all 8 repos with CI workflows -- 49 `@bytelyst/*` packages published to local Gitea +- local Gitea CI green for all 10 repos with CI workflows +- 56 `@bytelyst/*` packages published to local Gitea - `docker-prep.sh` retired from all repos Verified local FlowMonk Docker recipe (`NETWORK=corp`): @@ -208,16 +208,16 @@ On the target VM, the recipe simplifies to just `--build-arg GITEA_NPM_HOST=/dev/null \|\| true`) in COPY instructions | **BUG** | Removed — Docker COPY doesn't support shell redirects | both | -| 7 | MindLyst web Dockerfile used `pnpm run build -- --webpack` — pnpm passes `--webpack` as directory arg | **BUG** | Changed to `npx next build --webpack` | `learning_multimodal_memory_agents` | -| 8 | `@bytelyst/extraction` was missing from Gitea registry | **GAP** | Published (now 49 packages total) | common-plat | +| # | Finding | Severity | Fix | Repo | +| --- | ----------------------------------------------------------------------------------------------------- | -------- | ----------------------------------------------------- | ----------------------------------- | +| 6 | MindLyst + LysnrAI Dockerfiles used shell syntax (`2>/dev/null \|\| true`) in COPY instructions | **BUG** | Removed — Docker COPY doesn't support shell redirects | both | +| 7 | MindLyst web Dockerfile used `pnpm run build -- --webpack` — pnpm passes `--webpack` as directory arg | **BUG** | Changed to `npx next build --webpack` | `learning_multimodal_memory_agents` | +| 8 | `@bytelyst/extraction` was missing from Gitea registry | **GAP** | Published | common-plat | ### Docker build results — all PASS -| Repo | Image | Status | -|------|-------|--------| -| MindLyst | `mindlyst-backend:test` | ✅ | -| MindLyst | `mindlyst-web:test` | ✅ | -| LysnrAI | `lysnrai-backend:test` | ✅ | -| LysnrAI | `lysnrai-dashboard:test` | ✅ | +| Repo | Image | Status | +| -------- | ------------------------ | ------ | +| MindLyst | `mindlyst-backend:test` | ✅ | +| MindLyst | `mindlyst-web:test` | ✅ | +| LysnrAI | `lysnrai-backend:test` | ✅ | +| LysnrAI | `lysnrai-dashboard:test` | ✅ | (Standard repos were already Docker-verified during the initial migration.)