mirror of
https://github.com/okxlin/appstore.git
synced 2025-07-13 21:02:18 +08:00
feat:修改mixspace
This commit is contained in:
parent
193b4b8edc
commit
b865402b10
8
apps/mixspace/5/.env.sample
Normal file
8
apps/mixspace/5/.env.sample
Normal file
@ -0,0 +1,8 @@
|
||||
CONTAINER_NAME="mixspace"
|
||||
PANEL_APP_PORT_HTTP="40203"
|
||||
ALLOWED_ORIGINS="example.com"
|
||||
ENCRYPT_ENABLE="false"
|
||||
ENCRYPT_KEY=""
|
||||
JWT_SECRET="Np2qgqtiUayA857a_2KpAwe"
|
||||
TIME_ZONE="Asia/Shanghai"
|
||||
SUBNET_PREFIX="172.19.0"
|
@ -1,37 +1,54 @@
|
||||
additionalProperties:
|
||||
formFields:
|
||||
- default: 2333
|
||||
- default: 40203
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelEn: Port
|
||||
labelZh: 应用端口
|
||||
labelZh: 端口
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: example.com
|
||||
edit: true
|
||||
envKey: ALLOWED_ORIGINS
|
||||
labelEn: Allowed_Origins
|
||||
labelZh: 允许域名(前端绑定域名,不需要https://,多个使用英文逗号分割)
|
||||
labelEn: Allowed domain (multiple delimited with ",")
|
||||
labelZh: 被允许的域名 (多个使用英文逗号分割)
|
||||
required: true
|
||||
type: text
|
||||
- default: Np2qgqtiUayA857
|
||||
- default: Np2qgqtiUayA857a
|
||||
edit: true
|
||||
envKey: JWT_SECRET
|
||||
labelEn: Password
|
||||
labelZh: JWT密钥(16到32位字符,请一定修改至要求!)
|
||||
labelEn: JWT key (16 to 32 characters)
|
||||
labelZh: JWT 密钥 (16 到 32 位字符)
|
||||
random: true
|
||||
required: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default:
|
||||
- default: ''
|
||||
edit: true
|
||||
envKey: ENCRYPT_KEY
|
||||
labelEn: ENCRYPT_KEY
|
||||
labelZh: 加密密钥(非特殊需求不建议填写)
|
||||
required: false
|
||||
rule: paramCommon
|
||||
type: password
|
||||
- default:
|
||||
envKey: ENCRYPT_ENABLE
|
||||
labelEn: ENCRYPT_ENABLE
|
||||
labelZh: 是否开启加密(true或false,需要填写加密密钥)
|
||||
labelEn: Encryption key (not recommended for non-special needs, run "openssl rand -hex 32" on the terminal to obtain it)
|
||||
labelZh: 加密密钥 (非特殊需求不建议填写,终端执行 "openssl rand -hex 32" 获取)
|
||||
required: false
|
||||
type: text
|
||||
- default: "false"
|
||||
edit: true
|
||||
envKey: ENCRYPT_ENABLE
|
||||
labelEn: Whether to enable encryption (true or false, if you want to enable it, you need to enter the encryption key)
|
||||
labelZh: 是否开启加密 (true或false,开启则需要填写加密密钥)
|
||||
required: true
|
||||
type: text
|
||||
- default: Asia/Shanghai
|
||||
edit: true
|
||||
envKey: TIME_ZONE
|
||||
labelEn: Time zone
|
||||
labelZh: 时区
|
||||
required: true
|
||||
type: text
|
||||
- default: 172.19.0
|
||||
edit: true
|
||||
envKey: SUBNET_PREFIX
|
||||
labelEn: New docker network subnet prefix
|
||||
labelZh: 新 docker 网络子网前缀
|
||||
required: true
|
||||
type: text
|
||||
|
@ -1,12 +1,11 @@
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
app:
|
||||
mixspace:
|
||||
container_name: ${CONTAINER_NAME}
|
||||
image: innei/mx-server:5
|
||||
command: bash ./docker-run.sh
|
||||
environment:
|
||||
- TZ=Asia/Shanghai
|
||||
- TZ=${TIME_ZONE}
|
||||
- NODE_ENV=production
|
||||
- ALLOWED_ORIGINS=${ALLOWED_ORIGINS}
|
||||
- JWT_SECRET=${JWT_SECRET}
|
||||
@ -16,14 +15,8 @@ services:
|
||||
- ./data/mx-space:/root/.mx-space
|
||||
ports:
|
||||
- '${PANEL_APP_PORT_HTTP}:2333'
|
||||
depends_on:
|
||||
- mongo
|
||||
- redis
|
||||
links:
|
||||
- mongo
|
||||
- redis
|
||||
networks:
|
||||
- 1panel-network
|
||||
- mixspace-network
|
||||
restart: always
|
||||
healthcheck:
|
||||
test: ['CMD', 'curl', '-f', 'http://127.0.0.1:2333/api/v2/ping']
|
||||
@ -31,25 +24,39 @@ services:
|
||||
timeout: 30s
|
||||
retries: 5
|
||||
start_period: 30s
|
||||
depends_on:
|
||||
- mongo
|
||||
- redis
|
||||
links:
|
||||
- mongo
|
||||
- redis
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
mongo:
|
||||
container_name: mongo
|
||||
container_name: ${CONTAINER_NAME}-mongo
|
||||
image: mongo
|
||||
volumes:
|
||||
- ./data/db:/data/db
|
||||
networks:
|
||||
- 1panel-network
|
||||
- mixspace-network
|
||||
restart: always
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
redis:
|
||||
image: redis
|
||||
container_name: redis
|
||||
container_name: ${CONTAINER_NAME}-redis
|
||||
networks:
|
||||
- 1panel-network
|
||||
- mixspace-network
|
||||
restart: always
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
mixspace-network:
|
||||
driver: bridge
|
||||
ipam:
|
||||
driver: default
|
||||
config:
|
||||
- subnet: ${SUBNET_PREFIX}.0/16
|
@ -4,8 +4,7 @@ Mix Space 是一个一款简洁而不简单的个人博客系统,它够快,
|
||||
|
||||
## 注意事项
|
||||
|
||||
在此处你安装的是Mix-Space的后端,你还需要参照官方文档中的[前端主题](https://mx-space.js.org/themes
|
||||
)部分完成前端部署
|
||||
在此处你安装的是Mix-Space的后端,你还需要参照官方文档中的 [前端主题](https://mx-space.js.org/themes) 部分完成前端部署
|
||||
|
||||
## 主要功能:
|
||||
|
||||
|
8
apps/mixspace/latest/.env.sample
Normal file
8
apps/mixspace/latest/.env.sample
Normal file
@ -0,0 +1,8 @@
|
||||
CONTAINER_NAME="mixspace"
|
||||
PANEL_APP_PORT_HTTP="40203"
|
||||
ALLOWED_ORIGINS="example.com"
|
||||
ENCRYPT_ENABLE="false"
|
||||
ENCRYPT_KEY=""
|
||||
JWT_SECRET="Np2qgqtiUayA857a_2KpAwe"
|
||||
TIME_ZONE="Asia/Shanghai"
|
||||
SUBNET_PREFIX="172.19.0"
|
54
apps/mixspace/latest/data.yml
Normal file
54
apps/mixspace/latest/data.yml
Normal file
@ -0,0 +1,54 @@
|
||||
additionalProperties:
|
||||
formFields:
|
||||
- default: 40203
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelEn: Port
|
||||
labelZh: 端口
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: example.com
|
||||
edit: true
|
||||
envKey: ALLOWED_ORIGINS
|
||||
labelEn: Allowed domain (multiple delimited with ",")
|
||||
labelZh: 被允许的域名 (多个使用英文逗号分割)
|
||||
required: true
|
||||
type: text
|
||||
- default: Np2qgqtiUayA857a
|
||||
edit: true
|
||||
envKey: JWT_SECRET
|
||||
labelEn: JWT key (16 to 32 characters)
|
||||
labelZh: JWT 密钥 (16 到 32 位字符)
|
||||
random: true
|
||||
required: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: ''
|
||||
edit: true
|
||||
envKey: ENCRYPT_KEY
|
||||
labelEn: Encryption key (not recommended for non-special needs, run "openssl rand -hex 32" on the terminal to obtain it)
|
||||
labelZh: 加密密钥 (非特殊需求不建议填写,终端执行 "openssl rand -hex 32" 获取)
|
||||
required: false
|
||||
type: text
|
||||
- default: "false"
|
||||
edit: true
|
||||
envKey: ENCRYPT_ENABLE
|
||||
labelEn: Whether to enable encryption (true or false, if you want to enable it, you need to enter the encryption key)
|
||||
labelZh: 是否开启加密 (true或false,开启则需要填写加密密钥)
|
||||
required: true
|
||||
type: text
|
||||
- default: Asia/Shanghai
|
||||
edit: true
|
||||
envKey: TIME_ZONE
|
||||
labelEn: Time zone
|
||||
labelZh: 时区
|
||||
required: true
|
||||
type: text
|
||||
- default: 172.19.0
|
||||
edit: true
|
||||
envKey: SUBNET_PREFIX
|
||||
labelEn: New docker network subnet prefix
|
||||
labelZh: 新 docker 网络子网前缀
|
||||
required: true
|
||||
type: text
|
62
apps/mixspace/latest/docker-compose.yml
Normal file
62
apps/mixspace/latest/docker-compose.yml
Normal file
@ -0,0 +1,62 @@
|
||||
version: '3.8'
|
||||
services:
|
||||
mixspace:
|
||||
container_name: ${CONTAINER_NAME}
|
||||
image: innei/mx-server:latest
|
||||
command: bash ./docker-run.sh
|
||||
environment:
|
||||
- TZ=${TIME_ZONE}
|
||||
- NODE_ENV=production
|
||||
- ALLOWED_ORIGINS=${ALLOWED_ORIGINS}
|
||||
- JWT_SECRET=${JWT_SECRET}
|
||||
- ENCRYPT_KEY=${ENCRYPT_KEY}
|
||||
- ENCRYPT_ENABLE=${ENCRYPT_ENABLE}
|
||||
volumes:
|
||||
- ./data/mx-space:/root/.mx-space
|
||||
ports:
|
||||
- '${PANEL_APP_PORT_HTTP}:2333'
|
||||
networks:
|
||||
- mixspace-network
|
||||
restart: always
|
||||
healthcheck:
|
||||
test: ['CMD', 'curl', '-f', 'http://127.0.0.1:2333/api/v2/ping']
|
||||
interval: 1m30s
|
||||
timeout: 30s
|
||||
retries: 5
|
||||
start_period: 30s
|
||||
depends_on:
|
||||
- mongo
|
||||
- redis
|
||||
links:
|
||||
- mongo
|
||||
- redis
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
mongo:
|
||||
container_name: ${CONTAINER_NAME}-mongo
|
||||
image: mongo
|
||||
volumes:
|
||||
- ./data/db:/data/db
|
||||
networks:
|
||||
- mixspace-network
|
||||
restart: always
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
redis:
|
||||
image: redis
|
||||
container_name: ${CONTAINER_NAME}-redis
|
||||
networks:
|
||||
- mixspace-network
|
||||
restart: always
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
networks:
|
||||
mixspace-network:
|
||||
driver: bridge
|
||||
ipam:
|
||||
driver: default
|
||||
config:
|
||||
- subnet: ${SUBNET_PREFIX}.0/16
|
Binary file not shown.
Before Width: | Height: | Size: 8.2 KiB After Width: | Height: | Size: 4.3 KiB |
Loading…
Reference in New Issue
Block a user