fix: avoid production spacetimedb port conflict

This commit is contained in:
2026-05-03 00:49:36 +08:00
parent 019c8a2b03
commit 96f13bdfed
11 changed files with 50 additions and 16 deletions

View File

@@ -22,7 +22,7 @@ AUTH_REFRESH_COOKIE_SECURE=true
GENARRATIVE_AUTH_STORE_PATH=/var/lib/genarrative/auth/auth-store.json
GENARRATIVE_DEV_PASSWORD_ENTRY_AUTO_REGISTER_ENABLED=false
GENARRATIVE_SPACETIME_SERVER_URL=http://127.0.0.1:3000
GENARRATIVE_SPACETIME_SERVER_URL=http://127.0.0.1:3101
GENARRATIVE_SPACETIME_DATABASE=genarrative-prod
GENARRATIVE_SPACETIME_TOKEN=
GENARRATIVE_SPACETIME_POOL_SIZE=8

View File

@@ -55,7 +55,7 @@ server {
# 仅开放前端 SpacetimeDB SDK 运行所需的最小公网路由。
location ~ ^/v1/database/[^/]+/subscribe$ {
proxy_pass http://127.0.0.1:3000;
proxy_pass http://127.0.0.1:3101;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
@@ -64,7 +64,7 @@ server {
}
location ^~ /v1/identity {
proxy_pass http://127.0.0.1:3000;
proxy_pass http://127.0.0.1:3101;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";

View File

@@ -69,7 +69,7 @@ server {
# SpacetimeDB 只开放 TypeScript SDK 运行所需的最小公网路由。
location ~ ^/v1/database/[^/]+/subscribe$ {
proxy_pass http://127.0.0.1:3000;
proxy_pass http://127.0.0.1:3101;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
@@ -78,7 +78,7 @@ server {
}
location ^~ /v1/identity {
proxy_pass http://127.0.0.1:3000;
proxy_pass http://127.0.0.1:3101;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";

View File

@@ -8,7 +8,7 @@ Type=simple
User=spacetimedb
Group=spacetimedb
WorkingDirectory=/stdb
ExecStart=/stdb/spacetime --root-dir=/stdb start --listen-addr=127.0.0.1:3000
ExecStart=/stdb/spacetime --root-dir=/stdb start --listen-addr=127.0.0.1:3101
Restart=always
RestartSec=5
LimitNOFILE=1048576