feat(auth): migrate auth ui to unique domain

This commit is contained in:
RainbowBird
2026-06-09 00:15:34 +08:00
parent ff7c18694a
commit 57ba232432
38 changed files with 682 additions and 234 deletions
@@ -12,7 +12,7 @@ concurrency:
cancel-in-progress: true
jobs:
deploy:
deploy-stage-web:
name: Deploy - stage-web (server-dev)
runs-on: ubuntu-latest
permissions:
@@ -83,3 +83,50 @@ jobs:
echo "preview_url=$preview_url" >> "$GITHUB_OUTPUT"
echo "Preview URL: $preview_url"
deploy-auth-ui:
name: Deploy - ui-server-auth (server-dev)
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
environment:
name: AuthServerDev
url: https://server-dev.airi-server-auth.pages.dev/ui/
steps:
- uses: actions/checkout@v6
# Turborepo
- name: Cache turbo build setup
uses: actions/cache@v5
with:
path: .turbo
key: ${{ runner.os }}-turbo-auth-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-auth-
${{ runner.os }}-turbo-
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v6
with:
node-version: lts/*
cache: pnpm
- run: pnpm i -g wrangler@4
- run: pnpm install --frozen-lockfile
- run: pnpm run build:packages
- name: Build ui-server-auth
run: pnpm -F @proj-airi/ui-server-auth run build
env:
VITE_SERVER_URL: 'https://airi-server-dev.up.railway.app'
- name: Wrangler Pages Deploy
uses: cloudflare/wrangler-action@v3.14.1
with:
apiToken: ${{ secrets.AUTH_CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.AUTH_CLOUDFLARE_ACCOUNT_ID }}
command: pages deploy ./apps/ui-server-auth/dist --project-name=moeru-ai-airi-auth --branch=server-dev
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
- name: Print preview URL
run: |
echo "Preview URL: https://server-dev.airi-server-auth.pages.dev/ui/"