问题修复
This commit is contained in:
@@ -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`
|
||||
|
||||
45
apps/apifox-runner/slim/data.yml
Normal file
45
apps/apifox-runner/slim/data.yml
Normal 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
|
||||
22
apps/apifox-runner/slim/docker-compose.yml
Normal file
22
apps/apifox-runner/slim/docker-compose.yml
Normal 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
|
||||
2
apps/apifox-runner/slim/envs/default.env
Normal file
2
apps/apifox-runner/slim/envs/default.env
Normal file
@@ -0,0 +1,2 @@
|
||||
# copyright© 2024 XinJiang Ms Studio
|
||||
ENV_FILE=.env
|
||||
2
apps/apifox-runner/slim/envs/global.env
Normal file
2
apps/apifox-runner/slim/envs/global.env
Normal file
@@ -0,0 +1,2 @@
|
||||
# copyright© 2024 XinJiang Ms Studio
|
||||
TZ=Asia/Shanghai
|
||||
17
apps/apifox-runner/slim/scripts/init.sh
Normal file
17
apps/apifox-runner/slim/scripts/init.sh
Normal 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
|
||||
10
apps/apifox-runner/slim/scripts/uninstall.sh
Normal file
10
apps/apifox-runner/slim/scripts/uninstall.sh
Normal file
@@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
17
apps/apifox-runner/slim/scripts/upgrade.sh
Normal file
17
apps/apifox-runner/slim/scripts/upgrade.sh
Normal 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
|
||||
@@ -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}
|
||||
|
||||
@@ -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}
|
||||
|
||||
@@ -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}
|
||||
|
||||
@@ -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}
|
||||
|
||||
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user