Synced apps from source repository via GitHub Actions

This commit is contained in:
QYG2297248353
2025-08-26 09:24:07 +00:00
parent 864b869689
commit ddce9fc645
24 changed files with 335 additions and 2 deletions
+66
View File
@@ -0,0 +1,66 @@
# Postgres 服务 (前置检查) [必填]
PANEL_POSTGRES_TYPE=postgresql
# Redis 服务 (前置检查) [必填]
PANEL_REDIS_TYPE=redis
# 数据持久化路径 [必填]
AFFINE_ROOT_PATH=/home/affine
# WebUI 端口 [必填]
PANEL_APP_PORT_HTTP=3010
# 通讯端口 [必填]
PANEL_APP_PORT_COMMUNICATION=5555
# 服务外部地址 [必填]
AFFINE_SERVER_EXTERNAL_URL=http://127.0.0.1:3010
# 是否启用 HTTPS [必填]
AFFINE_SERVER_HTTPS=false
# SMTP 服务器地址 [必填]
MAILER_HOST=smtp.163.com
# SMTP 服务器端口 [必填]
MAILER_PORT=465
# 邮件发送者 [必填]
MAILER_SENDER=
# SMTP 用户名 [必填]
MAILER_USER=
# SMTP 密码 [必填]
MAILER_PASSWORD=
# 数据库 主机地址 [必填]
POSTGRES_HOST=127.0.0.1
# 数据库 端口 [必填]
POSTGRES_PORT=5432
# 数据库 名称 [必填]
POSTGRES_NAME=affine
# 数据库 用户名 [必填]
POSTGRES_USER=affine
# 数据库 密码 [必填]
POSTGRES_PASSWORD=
# Redis 主机 [必填]
REDIS_SERVER_HOST=127.0.0.1
# Redis 端口 [必填]
REDIS_SERVER_PORT=6379
# Redis 索引 (0-20) [必填]
REDIS_SERVER_DATABASE=0
# Redis 用户
REDIS_SERVER_USER=
# Redis 密码
REDIS_SERVER_PASSWORD=
+183
View File
@@ -0,0 +1,183 @@
additionalProperties:
formFields:
- child:
default: ""
envKey: PANEL_POSTGRES_SERVICE
required: true
type: service
default: postgresql
envKey: PANEL_POSTGRES_TYPE
labelZh: Postgres 服务 (前置检查)
labelEn: Postgres Service (Pre-check)
required: true
type: apps
values:
- label: PostgreSQL
value: postgresql
- child:
default: ""
envKey: PANEL_REDIS_SERVICE
required: true
type: service
default: redis
envKey: PANEL_REDIS_TYPE
labelZh: Redis 服务 (前置检查)
labelEn: Redis Service (Pre-check)
required: true
type: apps
values:
- label: Redis
value: redis
- default: "/home/affine"
edit: true
envKey: AFFINE_ROOT_PATH
labelZh: 数据持久化路径
labelEn: Data persistence path
required: true
type: text
- default: 3010
edit: true
envKey: PANEL_APP_PORT_HTTP
labelZh: WebUI 端口
labelEn: WebUI port
required: true
rule: paramPort
type: number
- default: 5555
edit: true
envKey: PANEL_APP_PORT_COMMUNICATION
labelZh: 通讯端口
labelEn: Communication port
required: true
rule: paramPort
type: number
- default: "http://127.0.0.1:3010"
edit: true
envKey: AFFINE_SERVER_EXTERNAL_URL
labelZh: 服务外部地址
labelEn: Service external address
required: true
type: text
- default: "false"
edit: true
envKey: AFFINE_SERVER_HTTPS
labelZh: 是否启用 HTTPS
labelEn: Enable HTTPS
required: true
type: select
values:
- label: 已开启
value: "true"
- label: 未开启
value: "false"
- default: "smtp.163.com"
edit: true
envKey: MAILER_HOST
labelZh: SMTP 服务器地址
labelEn: SMTP server address
required: true
type: text
- default: 465
edit: true
envKey: MAILER_PORT
labelZh: SMTP 服务器端口
labelEn: SMTP server port
required: true
rule: paramPort
type: number
- default: ""
edit: true
envKey: MAILER_SENDER
labelZh: 邮件发送者
labelEn: Email sender
required: true
type: text
- default: ""
edit: true
envKey: MAILER_USER
labelZh: SMTP 用户名
labelEn: SMTP username
required: true
type: text
- default: ""
edit: true
envKey: MAILER_PASSWORD
labelZh: SMTP 密码
labelEn: SMTP password
required: true
type: password
- default: "127.0.0.1"
edit: true
envKey: POSTGRES_HOST
labelZh: 数据库 主机地址
labelEn: Database Host
required: true
type: text
- default: 5432
edit: true
envKey: POSTGRES_PORT
labelZh: 数据库 端口
labelEn: Database Port
required: true
rule: paramPort
type: number
- default: "affine"
edit: true
envKey: POSTGRES_NAME
labelZh: 数据库 名称
labelEn: Database Name
required: true
rule: paramCommon
type: text
- default: "affine"
edit: true
envKey: POSTGRES_USER
labelZh: 数据库 用户名
labelEn: Database Username
required: true
type: text
- default: ""
edit: true
envKey: POSTGRES_PASSWORD
labelZh: 数据库 密码
labelEn: Database Password
random: true
required: true
rule: paramComplexity
type: password
- default: "127.0.0.1"
edit: true
envKey: REDIS_SERVER_HOST
labelZh: Redis 主机
labelEn: Redis Host
required: true
type: text
- default: 6379
edit: true
envKey: REDIS_SERVER_PORT
labelZh: Redis 端口
labelEn: Redis Port
required: true
rule: paramPort
type: number
- default: 0
edit: true
envKey: REDIS_SERVER_DATABASE
labelZh: Redis 索引 (0-20)
labelEn: Redis Index (0-20)
required: true
type: number
- default: ""
edit: true
envKey: REDIS_SERVER_USER
labelZh: Redis 用户
labelEn: Redis User
required: false
type: text
- default: ""
edit: true
envKey: REDIS_SERVER_PASSWORD
labelZh: Redis 密码
labelEn: Redis Password
required: false
type: password
@@ -0,0 +1,36 @@
networks:
1panel-network:
external: true
services:
affine:
command:
- sh
- -c
- node ./scripts/self-host-predeploy && node ./dist/index.js
container_name: affine
env_file:
- ./envs/global.env
- .env
environment:
- NODE_OPTIONS="--import=./scripts/register.js"
- AFFINE_CONFIG_PATH=/root/.affine/config
- REDIS_SERVER_HOST=redis
- DATABASE_URL=postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_NAME}
- NODE_ENV=production
- TELEMETRY_ENABLE=false
- AFFINE_SERVER_HOST=localhost
- AFFINE_SERVER_PORT=3010
- AFFINE_SERVER_HTTPS=false
- AFFINE_SERVER_EXTERNAL_URL=http://127.0.0.1:3010
image: ghcr.io/toeverything/affine-graphql:stable-e98f035
labels:
createdBy: Apps
networks:
- 1panel-network
ports:
- ${PANEL_APP_PORT_HTTP}:3010
- ${PANEL_APP_PORT_COMMUNICATION}:5555
restart: always
volumes:
- ${AFFINE_ROOT_PATH}/config:/root/.affine/config
- ${AFFINE_ROOT_PATH}/storage:/root/.affine/storage
@@ -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
@@ -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
@@ -13,7 +13,7 @@ services:
- DEBUG=false
- DEV=false
- LOG_LEVEL=INFO
image: jxxghp/moviepilot:2.7.6
image: jxxghp/moviepilot:2.7.7
labels:
createdBy: Apps
logging:
@@ -11,7 +11,7 @@ services:
- ./envs/global.env
environment:
- RUN_IN_CONTAINER=true
image: b3log/siyuan:v3.2.1
image: b3log/siyuan:v3.3.0
labels:
createdBy: Apps
networks:
+2
View File
@@ -0,0 +1,2 @@
# copyright© 2024 XinJiang Ms Studio
ENV_FILE=.env
+2
View File
@@ -0,0 +1,2 @@
# copyright© 2024 XinJiang Ms Studio
TZ=Asia/Shanghai
+10
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