From d6112931beaee036d0b3247828d8eb67692cd9a4 Mon Sep 17 00:00:00 2001 From: fivemoons Date: Tue, 2 Dec 2025 15:19:48 +0800 Subject: [PATCH] update teable --- teable/.env | 25 +++++++++++++++++++++++++ teable/docker-compose.yml | 11 +++-------- 2 files changed, 28 insertions(+), 8 deletions(-) create mode 100644 teable/.env diff --git a/teable/.env b/teable/.env new file mode 100644 index 0000000..e7aeb48 --- /dev/null +++ b/teable/.env @@ -0,0 +1,25 @@ +# 替换下面默认密码, 推荐使用 8 位以上的强密码。 +POSTGRES_PASSWORD=replace_this_password +REDIS_PASSWORD=replace_this_password +SECRET_KEY=replace_this_secret_key + +# 请将下面替换为可公开访问的地址 +PUBLIC_ORIGIN=http://127.0.0.1:3000 + +# --------------------- + +# Postgres +POSTGRES_HOST=teable-db +POSTGRES_PORT=5432 +POSTGRES_DB=teable +POSTGRES_USER=teable + +# Redis +REDIS_HOST=teable-cache +REDIS_PORT=6379 +REDIS_DB=0 + +# App +PRISMA_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB} +BACKEND_CACHE_PROVIDER=redis +BACKEND_CACHE_REDIS_URI=redis://default:${REDIS_PASSWORD}@${REDIS_HOST}:${REDIS_PORT}/${REDIS_DB} \ No newline at end of file diff --git a/teable/docker-compose.yml b/teable/docker-compose.yml index 7c1e404..8b5885a 100644 --- a/teable/docker-compose.yml +++ b/teable/docker-compose.yml @@ -5,7 +5,7 @@ services: ports: - '3000:3000' volumes: - - teable-data:/app/.assets:rw + - ./teable-data:/app/.assets:rw env_file: - .env environment: @@ -30,7 +30,7 @@ services: ports: - '42345:5432' volumes: - - teable-db:/var/lib/postgresql/data:rw + - ./teable-db:/var/lib/postgresql/data:rw environment: - POSTGRES_DB=${POSTGRES_DB} - POSTGRES_USER=${POSTGRES_USER} @@ -49,7 +49,7 @@ services: expose: - '6379' volumes: - - teable-cache:/data:rw + - ./teable-cache:/data:rw networks: - teable command: redis-server --appendonly yes --requirepass ${REDIS_PASSWORD} @@ -62,8 +62,3 @@ services: networks: teable: name: teable-network - -volumes: - teable-db: {} - teable-data: {} - teable-cache: {} \ No newline at end of file