mkdir -p /data/mindoc/{conf,uploads}
docker run -itd --name mindoc-test registry.cn-hangzhou.aliyuncs.com/mindoc/mindoc:v2.0
docker cp mindoc-test:/mindoc/conf/app.conf /data/mindoc/conf/
docker cp mindoc-test:/mindoc/conf/app.conf.example /data/mindoc/conf/
docker rm -f mindoc-test
vim /data/mindoc/docker-compose.yaml
version: '3'
services:
mindoc:
image: 'registry.cn-hangzhou.aliyuncs.com/mindoc/mindoc:v2.0'
restart: always
container_name: mindoc
# depends_on:
# - 172.17.0.1
volumes:
- /data/mindoc/uploads:/mindoc/uploads
- /data/mindoc/conf:/mindoc/conf
# - ./mindoc-data/headimgurl.jpg:/mindoc/static/images/headimgurl.jpg
# - ./mindoc-data/views:/mindoc/views
ports:
- '7117:8181'
environment:
TZ: Asia/Shanghai
MINDOC_DB_ADAPTER: mysql
MINDOC_DB_HOST: 172.17.0.1
MINDOC_DB_PORT: 7001
MINDOC_DB_DATABASE: mindoc_db
MINDOC_DB_USERNAME: root
MINDOC_DB_PASSWORD: "my123456"
docker-compose -f /data/mindoc/docker-compose.yaml up -d
vim /etc/nginx/nginx.conf
# 工具——文档管理工具
server {
listen 80;
server_name mindoc.***.cn;
charset utf-8;
location / {
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $http_host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://127.0.0.1:7117;
}
location ~ /\. {
deny all;
}
}
nginx -t
nginx -s reload
URL访问:mindoc.***.cn(默认用户名admin,密码123456)
docker-compose部署mindoc文档管理工具(支持md)
最新推荐文章于 2024-01-23 13:15:06 发布