1
0

feat:调整perfree-blog

This commit is contained in:
okxlin
2024-12-15 19:57:30 +08:00
parent 2da54dc132
commit 63bc4470c9
9 changed files with 93 additions and 67 deletions

View File

@@ -0,0 +1,10 @@
CONTAINER_NAME="perfree-blog"
DATA_PATH="./data"
PANEL_APP_PORT_HTTP=40337
PANEL_DB_HOST="mysql"
PANEL_DB_HOST_NAME="mysql"
PANEL_DB_NAME="perfree"
PANEL_DB_PORT=3306
PANEL_DB_TYPE="mysql"
PANEL_DB_USER="perfree"
PANEL_DB_USER_PASSWORD="perfree"

View File

@@ -0,0 +1,57 @@
additionalProperties:
formFields:
- child:
default: ""
envKey: PANEL_DB_HOST
required: true
type: service
default: mysql
envKey: PANEL_DB_TYPE
labelEn: Database Service
labelZh: 数据库服务
required: true
type: apps
values:
- label: MySQL
value: mysql
- label: LocalMySQL
value: localmysql
- default: "perfree"
envKey: PANEL_DB_NAME
labelEn: Database
labelZh: 数据库名
random: true
required: true
rule: paramCommon
type: text
- default: "perfree"
envKey: PANEL_DB_USER
labelEn: User
labelZh: 数据库用户
random: true
required: true
rule: paramCommon
type: text
- default: "perfree"
envKey: PANEL_DB_USER_PASSWORD
labelEn: Password
labelZh: 数据库用户密码
random: true
required: true
rule: paramComplexity
type: password
- default: "40337"
edit: true
envKey: PANEL_APP_PORT_HTTP
labelEn: Port
labelZh: 端口
required: true
rule: paramPort
type: number
- default: "./data"
edit: true
envKey: DATA_PATH
labelEn: Data Path
labelZh: 数据路径
required: true
type: text

View File

@@ -0,0 +1,20 @@
services:
perfree-blog:
image: "registry.cn-hangzhou.aliyuncs.com/perfree/perfree_blog:v4.0.11"
container_name: ${CONTAINER_NAME}
restart: always
networks:
- 1panel-network
ports:
- ${PANEL_APP_PORT_HTTP}:8080
volumes:
- "${DATA_PATH}:/perfree-server/resources"
environment:
SPRING_DATASOURCE_URL: jdbc:${PANEL_DB_TYPE}://${PANEL_DB_HOST}:${PANEL_DB_PORT}/${PANEL_DB_NAME}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&nullCatalogMeansCurrent=true
SPRING_DATASOURCE_USERNAME: ${PANEL_DB_USER}
SPRING_DATASOURCE_PASSWORD: ${PANEL_DB_USER_PASSWORD}
labels:
createdBy: "Apps"
networks:
1panel-network:
external: true