Skip to content

feat: APISIX standalone gateway with access tiers - #1

Open
sitthadara wants to merge 3 commits into
mainfrom
feat/apisix-gateway
Open

sitthadara wants to merge 3 commits into
mainfrom
feat/apisix-gateway

Conversation

@sitthadara

Copy link
Copy Markdown
Member

Summary

  • APISIX 3.13 in standalone mode (no etcd, no Admin API). Routes are baked into conf/apisix.yaml.
  • Upstreams use <svc>.${{UPSTREAM_NAMESPACE}}.svc.cluster.local. One image works in SIT, UAT, production and PR previews.
  • Access tiers, path /<svc>/<access>/...:
    • public/: open to everyone.
    • secure/: forward-auth to user at GET /private/auth/verify, sets X-User-Id.
    • private/: 403.
    • Anything else: 404.
  • CI (.github/workflows/build.yaml):
    • PR labelled preview pushes ghcr.io/cu-devclub/cugrader-gateway:<head sha>, which Argo CD deploys as gateway-pr-<n>.
    • Merge to main pushes :<sha> and :latest, then bumps the SIT newTag in CUGrader-infrastructure.

Test plan

  • Local docker test with fake user upstream: public 200, secure 401 without token and 200 with it, private 403 (also %70rivate, //, ..), unknown path 404, no error logs.
  • CI pushes the preview image.
  • Argo CD creates gateway-pr-<n> and the pod becomes Ready.

Before merge

  • Add repo secret INFRA_REPO_TOKEN (PAT, contents write on CUGrader-infrastructure). Without it the SIT bump job fails.

🤖 Generated with Claude Code

Standalone APISIX image with routes baked in conf/apisix.yaml.
Upstreams resolve via UPSTREAM_NAMESPACE so one image serves every env.
/<svc>/public open, /<svc>/secure behind forward-auth to user service,
/<svc>/private denied. CI pushes ghcr image for preview PRs and bumps
SIT tag in CUGrader-infrastructure on merge to main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sitthadara sitthadara added the preview Deploy PR env via Argo CD label Nov 12, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Preview environment

https://pr-1-gateway-grader-sit.sittha.net

Commit 7e6ad76fb8d6b32687980767a14af2ceff6c3727. Argo CD deploys it within ~2 minutes of this comment. Backends come from SIT.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

preview Deploy PR env via Argo CD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant