Skip to content

ci: add GitHub Actions checks and Docker image publishing#39

Open
Digvijay-x1 wants to merge 3 commits into
superloglabs:mainfrom
Digvijay-x1:chore/ci-cd-checks
Open

ci: add GitHub Actions checks and Docker image publishing#39
Digvijay-x1 wants to merge 3 commits into
superloglabs:mainfrom
Digvijay-x1:chore/ci-cd-checks

Conversation

@Digvijay-x1

@Digvijay-x1 Digvijay-x1 commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

This PR adds GitHub Actions so PRs and branch pushes run the basic project checks automatically.

The CI workflow installs pnpm, validates package/Turbo config, runs typechecks, runs the test suite against Postgres, and builds the repo. I also added a Docker workflow that builds the API, proxy, worker, web, and collector images on PRs, and publishes them to GHCR from main, tags, or manual runs.

While wiring this up, I added missing package-level test scripts so turbo run test has a real workspace task to execute, quoted test globs so Node receives them correctly, and tightened Turbo’s test env passthrough to only the values CI needs.

This file apps/api/src/github.test.ts was missed by previous test runs.

** I have not added linting completely because there were a few linting issues currently.


Summary by cubic

Add CI to validate config, typecheck, run tests against Postgres, and build on PRs and pushes. Add Docker image builds and GHCR publishing, and ensure all workspace and web tests run in Node-based CI.

  • New Features

    • CI: validate package/Turbo config with biome, typecheck, test with Postgres service, and build using pnpm/turbo.
    • Docker: build api, proxy, worker, web, and collector images; tag via docker/metadata-action; publish to ghcr.io (non-PRs); cache per-service.
  • Refactors

    • Replace glob-based test scripts with find | sort | xargs tsx --test across apps/packages; add root test to run turbo run test.
    • Update turbo.json: pass only BETTER_AUTH_SECRET and DATABASE_URL to tests; include .next/** in build outputs and exclude .next/cache/**.
    • Fix apps/api/src/github.test.ts assertions for resolved reason fields; minor seed formatting.
    • Shim navigator and dynamically import the web diff model in tests to run under Node in CI.

Written for commit 9552872. Summary will update on new commits.

Review in cubic

Add CI coverage for package config validation, typechecking, tests, and builds, with a Postgres service for the DB-backed API tests. Add a separate Docker workflow that builds service images on PRs and publishes GHCR images from main, tags, and manual runs.

Full repo lint is not enabled yet because the current tree has few existing biome diagnostics, so CI starts with the checks that are green and useful today: config validation, typecheck, tests, and build.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 11 files

Re-trigger cubic

@Digvijay-x1 Digvijay-x1 marked this pull request as draft June 8, 2026 21:29
@arseniycodes

Copy link
Copy Markdown
Contributor

Looks good from a first glance! Feel free to set as 'ready to review' whenever ready

The @pierre/diffs package reads navigator.userAgent during module load, which breaks the Node.js test environment used by GitHub Actions. Add a minimal navigator shim before dynamically importing the incident PR diff model so the web test suite can run in CI.
@Digvijay-x1 Digvijay-x1 force-pushed the chore/ci-cd-checks branch from 81ab17b to 9552872 Compare June 9, 2026 16:22
@Digvijay-x1 Digvijay-x1 marked this pull request as ready for review June 9, 2026 16:26

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 12 files

Re-trigger cubic

@Digvijay-x1

Copy link
Copy Markdown
Contributor Author

Now everything is green in my Actions ☘

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants