fix: prepare vibework propose brand-domain proxy
All checks were successful
CI and Production Smoke / smoke (push) Successful in 6s
All checks were successful
CI and Production Smoke / smoke (push) Successful in 6s
This commit is contained in:
@@ -16,6 +16,8 @@ RUN pnpm install --no-frozen-lockfile
|
||||
# 2. Build the project
|
||||
FROM base AS builder
|
||||
WORKDIR /app
|
||||
ARG NEXT_PUBLIC_ASSET_PREFIX=""
|
||||
ENV NEXT_PUBLIC_ASSET_PREFIX=$NEXT_PUBLIC_ASSET_PREFIX
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY --from=deps /app/apps/web/node_modules ./apps/web/node_modules
|
||||
COPY --from=deps /app/packages/contracts/node_modules ./packages/contracts/node_modules
|
||||
|
||||
@@ -28,6 +28,7 @@ VIBEWORK_JOB_SECRET="your-cron-job-secret"
|
||||
# A2A demand funnel:外部 Agent 導流需求方到 VibeWork paid intake
|
||||
VIBEWORK_SITE_URL="https://vibework.wooo.work"
|
||||
NEXT_PUBLIC_VIBEWORK_SITE_URL="https://vibework.wooo.work"
|
||||
NEXT_PUBLIC_ASSET_PREFIX="https://agent.wooo.work"
|
||||
AGENT_GATEWAY_URL="https://agent.wooo.work"
|
||||
VIBEWORK_TREASURY_USDC_ADDRESS=""
|
||||
VIBEWORK_TREASURY_WALLET_LABEL="USDC Treasury"
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
import type { NextConfig } from "next";
|
||||
|
||||
const assetPrefix = process.env.NEXT_PUBLIC_ASSET_PREFIX?.trim().replace(/\/$/, "");
|
||||
|
||||
const nextConfig: NextConfig = {
|
||||
transpilePackages: ["@agent-bounty/contracts"],
|
||||
output: "standalone",
|
||||
assetPrefix: assetPrefix || undefined,
|
||||
};
|
||||
|
||||
export default nextConfig;
|
||||
|
||||
@@ -40,6 +40,8 @@ services:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
args:
|
||||
NEXT_PUBLIC_ASSET_PREFIX: ${NEXT_PUBLIC_ASSET_PREFIX:-https://agent.wooo.work}
|
||||
container_name: agent_bounty_web
|
||||
restart: always
|
||||
ports:
|
||||
@@ -56,6 +58,7 @@ services:
|
||||
- VIBEWORK_JOB_SECRET=${VIBEWORK_JOB_SECRET:-}
|
||||
- VIBEWORK_SITE_URL=${VIBEWORK_SITE_URL:-https://vibework.wooo.work}
|
||||
- NEXT_PUBLIC_VIBEWORK_SITE_URL=${NEXT_PUBLIC_VIBEWORK_SITE_URL:-https://vibework.wooo.work}
|
||||
- NEXT_PUBLIC_ASSET_PREFIX=${NEXT_PUBLIC_ASSET_PREFIX:-https://agent.wooo.work}
|
||||
- AGENT_GATEWAY_URL=${AGENT_GATEWAY_URL:-https://agent.wooo.work}
|
||||
- VIBEWORK_TREASURY_USDC_ADDRESS=${VIBEWORK_TREASURY_USDC_ADDRESS:-}
|
||||
- VIBEWORK_TREASURY_WALLET_LABEL=${VIBEWORK_TREASURY_WALLET_LABEL:-USDC Treasury}
|
||||
|
||||
39
ops/nginx/vibework-propose-proxy.conf
Normal file
39
ops/nginx/vibework-propose-proxy.conf
Normal file
@@ -0,0 +1,39 @@
|
||||
# Nginx snippet for 192.168.0.188 / vibework.wooo.work.
|
||||
# Purpose: keep A2A paid intake on the VibeWork brand domain while the agent app
|
||||
# serves /propose and /propose/success from port 3004.
|
||||
#
|
||||
# Place these locations inside the existing HTTPS server block for:
|
||||
# server_name vibework.wooo.work;
|
||||
#
|
||||
# The web image should be built with:
|
||||
# NEXT_PUBLIC_ASSET_PREFIX=https://agent.wooo.work
|
||||
#
|
||||
# That avoids collisions with the official VibeWork site's own /_next assets.
|
||||
|
||||
location = /propose {
|
||||
proxy_pass http://127.0.0.1:3004;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header X-Forwarded-Host $host;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_read_timeout 300s;
|
||||
proxy_connect_timeout 60s;
|
||||
}
|
||||
|
||||
location ^~ /propose/ {
|
||||
proxy_pass http://127.0.0.1:3004;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header X-Forwarded-Host $host;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_read_timeout 300s;
|
||||
proxy_connect_timeout 60s;
|
||||
}
|
||||
Reference in New Issue
Block a user