网络模式

This commit is contained in:
sijinhui 2024-05-11 22:07:48 +08:00
parent 0914682095
commit 7324a0ba08
3 changed files with 12 additions and 10 deletions

View File

@ -1,9 +1,9 @@
name: PRO DEPLOY TO TY
on:
workflow_dispatch:
push:
branches:
- main
# push:
# branches:
# - main
# paths:
# - 'app/**'
# - 'public/**'

View File

@ -65,9 +65,10 @@ COPY --from=builder /app/node_modules/sharp ./node_modules/sharp
RUN rm -f .env
EXPOSE 3000
EXPOSE 23000
ENV KEEP_ALIVE_TIMEOUT=30
ENV HOSTNAME=""
ENV HOSTNAME=127.0.0.1
ENV PORT=23000
CMD if [ -n "$PROXY_URL" ]; then \
export HOSTNAME="127.0.0.1"; \

View File

@ -12,8 +12,9 @@ services:
# depends_on:
# db:
# condition: service_healthy
ports:
- "127.0.0.1:23000:3000"
# ports:
# - "127.0.0.1:23000:23000"
network_mode: "host"
environment:
- TZ=Asia/Shanghai
- OPENAI_API_KEY=$OPENAI_API_KEY
@ -56,6 +57,6 @@ services:
max-size: "10m"
max-file: "1"
networks:
chatgpt-ns:
external: true
#networks:
# chatgpt-ns:
# external: true