docker-compose部署Minio

minio部署以及picGo图床设置

docker-compose.yml如下

http版本

version: "3.7"
services:
  minio:
    image: "minio/minio"
    container_name: minio
    ports:
      - "9000:9000"
      - "9001:9001"
    volumes:
      - "./minio/data1:/data1"
      - "./minio/data2:/data2"
    command: server --console-address ":9001" http://minio/data{1...2}
    environment:
      - MINIO_ROOT_USER=zyy # 登录web console的用户名
      - MINIO_ROOT_PASSWORD=TaWahThu # 登录web console的密码

https版本

在将ssl证书文件拷贝到当前目录

version: "3.7"
services:
  minio:
    image: "minio/minio"
    container_name: minio
    ports:
      - "9000:9000" #api端口
      - "9001:9001" #web端口
    volumes:
      - "./minio/data1:/data1"
      - "./minio/data2:/data2"
      - "./public.crt:/root/.minio/certs/public.crt"
      - "./private.key:/root/.minio/certs/private.key"
    command: server --address ':9000' --console-address ":9001" http://minio/data{1...2}
    environment:
      - MINIO_ROOT_USER=zyy
      - MINIO_ROOT_PASSWORD=TaWahThu
      - MINIO_SERVER_URL=https://guiguzi.eu.org:9000
      - MINIO_BROWSER_REDIRECT_URL=https://guiguzi.eu.org:9001
    privileged: true
    restart: always

启动

docker-compose up -d

访问web console

http://host-ip:9000

image-20240317100624106

picGO图床

安装minio

image-20240317100046196

配置minio

http版本配置

image-20240317124113372

https配置

image-20240317123304459

posted on 2024-03-17 10:07  ngu2020  阅读(525)  评论(0编辑  收藏  举报