问题修复

This commit is contained in:
ms
2025-10-27 15:11:21 +08:00
parent be377f7b52
commit 90f2ee7eaa
13 changed files with 135 additions and 12 deletions

View File

@@ -33,6 +33,14 @@ API 文档和 API 开发调试使用同一个工具API 调试完成后即可
## 安装说明
### 版本说明
- `latest`:通用版
包含 Runner 所有功能及以下外部程序语言环境Nodejs 18,Java 21,Python 3,PHP 8
- `slim`:精简版
在精简版中,包含 Runner 所有功能及以下外部程序语言环境Nodejs 18
### 应用服务地址
默认值:`https://api.apifox.cn`

View File

@@ -0,0 +1,45 @@
additionalProperties:
formFields:
- default: "/home/apifox-runner"
edit: true
envKey: APIFOX_RUNNER_ROOT_PATH
labelZh: 数据持久化路径
labelEn: Data persistence path
required: true
type: text
- default: 4524
edit: true
envKey: PANEL_APP_PORT_HTTP
labelZh: WebUI 端口
labelEn: WebUI port
required: true
rule: paramPort
type: number
- default: "https://api.apifox.cn"
edit: true
envKey: SERVER_APP_BASE_URL
labelZh: 应用服务地址
labelEn: App Server address
required: true
type: text
- default: ""
edit: true
envKey: ACCESS_TOKEN
labelZh: 访问令牌
labelEn: Access Token
required: true
type: text
- default: 0
edit: true
envKey: TEAM_ID
labelZh: 团队 ID
labelEn: Team ID
required: true
type: number
- default: 0
edit: true
envKey: RUNNER_ID
labelZh: Runner ID
labelEn: Runner ID
required: true
type: number

View File

@@ -0,0 +1,22 @@
networks:
1panel-network:
external: true
services:
apifox-runner:
image: registry.cn-hangzhou.aliyuncs.com/apifox/self-hosted-general-runner:slim
container_name: ${CONTAINER_NAME}
labels:
createdBy: "Apps"
restart: always
networks:
- 1panel-network
ports:
- ${PANEL_APP_PORT_HTTP}:4524
env_file:
- ${GLOBAL_ENV_FILE:-/etc/1panel/envs/global.env}
- ${ENV_FILE:-/etc/1panel/envs/default.env}
volumes:
- ${APIFOX_RUNNER_ROOT_PATH}/runner:/opt/runner
environment:
- TZ=Asia/Shanghai

View File

@@ -0,0 +1,2 @@
# copyright© 2024 XinJiang Ms Studio
ENV_FILE=.env

View File

@@ -0,0 +1,2 @@
# copyright© 2024 XinJiang Ms Studio
TZ=Asia/Shanghai

View File

@@ -0,0 +1,17 @@
#!/bin/bash
if [ -f .env ]; then
source .env
# setup-1 add default values
CURRENT_DIR=$(pwd)
sed -i '/^ENV_FILE=/d' .env
sed -i '/^GLOBAL_ENV_FILE=/d' .env
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
echo "GLOBAL_ENV_FILE=${CURRENT_DIR}/envs/global.env" >> .env
echo "Check Finish."
else
echo "Error: .env file not found."
fi

View File

@@ -0,0 +1,10 @@
#!/bin/bash
if [ -f .env ]; then
source .env
echo "Check Finish."
else
echo "Error: .env file not found."
fi

View File

@@ -0,0 +1,17 @@
#!/bin/bash
if [ -f .env ]; then
source .env
# setup-1 add default values
CURRENT_DIR=$(pwd)
sed -i '/^ENV_FILE=/d' .env
sed -i '/^GLOBAL_ENV_FILE=/d' .env
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
echo "GLOBAL_ENV_FILE=${CURRENT_DIR}/envs/global.env" >> .env
echo "Check Finish."
else
echo "Error: .env file not found."
fi

View File

@@ -19,7 +19,7 @@ services:
- ${GLOBAL_ENV_FILE:-/etc/1panel/envs/global.env}
- ${ENV_FILE:-/etc/1panel/envs/default.env}
environment:
- DISABLE_TELEMETRY = 1
- REMOVE_TRAILING_SLASH = 1
- DISABLE_TELEMETRY=1
- REMOVE_TRAILING_SLASH=1
- DATABASE_TYPE=mysql
- DATABASE_URL=mysql://${DB_USERNAME}:${DB_PASSWORD}@${DB_HOSTNAME}:${DB_PORT}/${DB_DATABASE_NAME}

View File

@@ -19,7 +19,7 @@ services:
- ${GLOBAL_ENV_FILE:-/etc/1panel/envs/global.env}
- ${ENV_FILE:-/etc/1panel/envs/default.env}
environment:
- DISABLE_TELEMETRY = 1
- REMOVE_TRAILING_SLASH = 1
- DISABLE_TELEMETRY=1
- REMOVE_TRAILING_SLASH=1
- DATABASE_TYPE=mysql
- DATABASE_URL=mysql://${DB_USERNAME}:${DB_PASSWORD}@${DB_HOSTNAME}:${DB_PORT}/${DB_DATABASE_NAME}

View File

@@ -17,7 +17,7 @@ services:
- ${GLOBAL_ENV_FILE:-/etc/1panel/envs/global.env}
- ${ENV_FILE:-/etc/1panel/envs/default.env}
environment:
- DISABLE_TELEMETRY = 1
- REMOVE_TRAILING_SLASH = 1
- DISABLE_TELEMETRY=1
- REMOVE_TRAILING_SLASH=1
- DATABASE_TYPE=postgresql
- DATABASE_URL=postgresql://${DB_USERNAME}:${DB_PASSWORD}@${DB_HOSTNAME}:${DB_PORT}/${DB_DATABASE_NAME}

View File

@@ -17,7 +17,7 @@ services:
- ${GLOBAL_ENV_FILE:-/etc/1panel/envs/global.env}
- ${ENV_FILE:-/etc/1panel/envs/default.env}
environment:
- DISABLE_TELEMETRY = 1
- REMOVE_TRAILING_SLASH = 1
- DISABLE_TELEMETRY=1
- REMOVE_TRAILING_SLASH=1
- DATABASE_TYPE=postgresql
- DATABASE_URL=postgresql://${DB_USERNAME}:${DB_PASSWORD}@${DB_HOSTNAME}:${DB_PORT}/${DB_DATABASE_NAME}

View File

@@ -31,11 +31,11 @@ additionalProperties:
required: true
rule: paramPort
type: number
- default: 9994
- default: 9993
edit: true
envKey: PANEL_APP_PORT_API
labelZh: API 端口
labelEn: API Port
envKey: PANEL_APP_PORT_ZT
labelZh: Zerotier 端口
labelEn: Zerotier port
required: true
rule: paramPort
type: number