diff --git a/.github/workflows/deploy-marketplace.yml b/.github/workflows/deploy-marketplace.yml index 4efd138a..3682b3ee 100644 --- a/.github/workflows/deploy-marketplace.yml +++ b/.github/workflows/deploy-marketplace.yml @@ -30,7 +30,7 @@ jobs: S3_ACCESS_KEY: ${{ secrets.S3_ACCESS_KEY }} S3_SECRET_KEY: ${{ secrets.S3_SECRET_KEY }} S3_BUCKET: ${{ secrets.S3_BUCKET }} - run: bun run deploy:marketplace-data + run: bun ./scripts/deploy-marketplace.ts - name: Notify deployment success if: success() diff --git a/.gitignore b/.gitignore index ec30d574..c3ecd02b 100644 --- a/.gitignore +++ b/.gitignore @@ -10,5 +10,3 @@ pnpm-lock.yaml *.local *.local.* local/ -.env.* -!.env.*.template diff --git a/package.json b/package.json index 6bbe1d56..5e430444 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "build:pkg": "bun --cwd modules/tool build", "build:sdk": "bun run --cwd sdk build", "build:marketplace": "bun run build:pkg && bun ./modules/tool/build/build-json.ts", - "deploy:marketplace-data": "bun --env-file=.env.marketplace ./scripts/deploy-marketplace.ts", + "deploy:marketplace-data": "bun --env-file=.env.marketplace.local ./scripts/deploy-marketplace.ts", "prepare": "husky install", "lint": "node_modules/.bin/eslint --fix", "prettier": "prettier --write \"./**/*.{ts,js,json}\"" diff --git a/runtime/.env.template b/runtime/.env.template new file mode 100644 index 00000000..6ca5ca3e --- /dev/null +++ b/runtime/.env.template @@ -0,0 +1,39 @@ +PORT=3000 +AUTH_TOKEN=xxx + +# Log level: debug,info,warn,error +LOG_LEVEL=info + +# Model provider sort +MODEL_PROVIDER_PRIORITY= + +# Signoz +SIGNOZ_BASE_URL= +SIGNOZ_SERVICE_NAME=fastgpt-plugin + +# S3 Config +# Customize S3 Base URL, for example: https://s3.example.com, make sure you can access your files via https://s3.example.com/[bucket]/[objectname] +S3_EXTERNAL_BASE_URL= +S3_ENDPOINT=localhost +S3_PORT=9000 +S3_USE_SSL=false +S3_ACCESS_KEY=minioadmin +S3_SECRET_KEY=minioadmin +S3_PUBLIC_BUCKET=fastgpt-public # 公开读私有写桶。用于系统工具,创建的临时文件,存储的桶。 +S3_PRIVATE_BUCKET=fastgpt-private # 私有读写桶。用于系统插件热安装文件的桶。 + +# Signoz +SIGNOZ_BASE_URL= +SIGNOZ_SERVICE_NAME=fastgpt-plugin + +# MongoDB connection string +# Replace 'myusername' and 'mypassword' with your actual MongoDB credentials and ensure the database 'fastgpt' exists. +MONGODB_URI=mongodb://myusername:mypassword@localhost:27017/fastgpt?authSource=admin&directConnection=true +REDIS_URL=redis://default:mypassword@127.0.0.1:6379 + +# 安全配置 +# 工具网络请求,最大请求和响应体 +SERVICE_REQUEST_MAX_CONTENT_LENGTH=10 +# 最大 API 请求体大小 +MAX_API_SIZE=10 +# DISABLE_DEV_TOOLS=false # 禁用 Dev 插件载入