docker部署kodbox个人网盘
拉去镜像
docker pull tznb/kodbox:1.15
docker images
创建并启动容器
docker run -d -it --name kodbox -p 1111:80 -v /data/docker/kodbox:/var/www/html --restart=always tznb/kodbox:1.15 #1111端口可以改
docker ps #查看运行状态
访问
下载可道云客户端
切换到自己的服务器,然后登录管理员账号就可以访问啦
客户端地址:https://kodcloud.com/download/
yml文件一键部署
vim kodbox.yaml
# 编写compose文件:
cat > kodbox.yml << EOF
version: '3.0'
services:
kodcloud:
container_name: kodcloud
image: kodcloud/kodbox
restart: always
ports:
- 1111:80
depends_on:
- mysql
- redis
mysql:
container_name: mysql
image: mysql:8.0.29
restart: always
volumes:
- /root/docker/mysql/data:/var/lib/mysql
- /root/docker/mysql/conf:/etc/mysql/conf.d
- /root/docker/mysql/logs:/logs
ports:
- 9004:3306
environment:
- "MYSQL_ROOT_PASSWORD=2002"
redis:
container_name: redis
image: redis:5.0
restart: always
volumes:
- /root/docker/redis/data:/data
- /root/docker/redis/redis.conf:/etc/redis/redis.conf
ports:
- 9005:6379
EOF
yum install -y docker-compose
docker-compose up -d
访问即可
Comments NOTHING