mirror of
https://github.com/cedar2025/Xboard.git
synced 2025-01-22 10:38:14 -05:00
修改1panel部署文档
This commit is contained in:
parent
9ae6fbaaa7
commit
bcc478a829
46
.docker/onepanel/compose.sample.yaml
Normal file
46
.docker/onepanel/compose.sample.yaml
Normal file
@ -0,0 +1,46 @@
|
||||
networks:
|
||||
1panel-network:
|
||||
driver: bridge
|
||||
external: true
|
||||
services:
|
||||
web:
|
||||
image: ghcr.io/cedar2025/xboard:new
|
||||
volumes:
|
||||
- ./.docker/.data/redis/:/data/
|
||||
- ./.env:/www/.env
|
||||
- ./.docker/.data/:/www/.docker/.data
|
||||
- ./storage/logs:/www/storage/logs
|
||||
- ./storage/theme:/www/storage/theme
|
||||
environment:
|
||||
- docker=true
|
||||
depends_on:
|
||||
- redis
|
||||
# network_mode: host
|
||||
networks:
|
||||
- 1panel-network
|
||||
command: php artisan octane:start --host=0.0.0.0 --port=7001
|
||||
restart: on-failure
|
||||
ports:
|
||||
- 7001:7001
|
||||
horizon:
|
||||
image: ghcr.io/cedar2025/xboard:new
|
||||
volumes:
|
||||
- ./.docker/.data/redis/:/data/
|
||||
- ./.env:/www/.env
|
||||
- ./.docker/.data/:/www/.docker/.data
|
||||
- ./storage/logs:/www/storage/logs
|
||||
restart: on-failure
|
||||
# network_mode: host
|
||||
command: php artisan horizon
|
||||
networks:
|
||||
- 1panel-network
|
||||
depends_on:
|
||||
- redis
|
||||
redis:
|
||||
image: redis:7-alpine
|
||||
command: redis-server --unixsocket /data/redis.sock --unixsocketperm 777 --save 900 1 --save 300 10 --save 60 10000
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- 1panel-network
|
||||
volumes:
|
||||
- ./.docker/.data/redis:/data
|
@ -62,11 +62,16 @@ apt update && apt install -y git
|
||||
yum update && yum install -y git
|
||||
|
||||
# 克隆代码
|
||||
git clone -b compose-new --depth 1 https://github.com/cedar2025/Xboard ./
|
||||
git clone -b new --depth 1 https://github.com/cedar2025/Xboard ./
|
||||
|
||||
# 复制配置文件
|
||||
cp .docker/onepanel/compose.sample.yaml compose.yaml
|
||||
|
||||
# 安装依赖并初始化
|
||||
docker compose run -it --rm web php artisan xboard:install
|
||||
```
|
||||
> ⚠️ Mysql的连接地址需要使用1panel中Mysql菜单中连接信息里的容器连接地址,而不是本地的localhost地址。
|
||||
![示例图](./images/1panel_mysql.png)
|
||||
> 安装时选择使用内置 Redis,并输入之前创建的数据库信息
|
||||
> 安装完成后请保存返回的后台地址和管理员账号密码
|
||||
|
||||
|
BIN
docs/images/1panel_mysql.png
Normal file
BIN
docs/images/1panel_mysql.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 228 KiB |
Loading…
Reference in New Issue
Block a user