html购物网站源码,江苏今天刚刚的最新新闻,民房做酒店出租网站app,网页游戏直接玩单机多副本docker-compose部署minio
简单介绍
如果服务器有限可以单机挂载多硬盘实现多副本容错#xff08;生产不推荐#xff09;
部署好的文件状态 有两个重要文件 docker-compose.yaml和nginx.conf
docker-compose.yaml是docker部署容器的配置信息包括4个minio和1个ng…单机多副本docker-compose部署minio
简单介绍
如果服务器有限可以单机挂载多硬盘实现多副本容错生产不推荐
部署好的文件状态 有两个重要文件 docker-compose.yaml和nginx.conf
docker-compose.yaml是docker部署容器的配置信息包括4个minio和1个nginx容器
部署好的状态 操作步骤 安装docker yum install docker安装docker-compose curl -L https://github.com/docker/compose/releases/download/1.21.1/docker-compose-uname -s-uname -m -o /usr/local/bin/docker-compose 放置配置docker-compose.yaml文件和nginx.conf mkdir /home/minios/ #创建文件夹运行docker-compose.yaml systemctl enable docker
systemctl start docker
systemctl status docker
docker-compose -f docker-compose.yaml up -d
docker images #查看docker服务镜像
docker ps #正在运行的docker容器
docker ps -a #全部的docker容器
docker logs --tail 100 容器ID #查看容器日志信息
telnet 127.0.0.1 9000检查是否成功创建文件桶 docker-compose.yaml
version: 3.3# starts 4 docker containers running minio server instances.
# using nginx reverse proxy, load balancing, you can access
# it through port 9000.
services:minio1:image: minio/minio:RELEASE.2021-04-22T15-44-28Zvolumes:- ./data1-1:/data1- ./data1-2:/data2expose:- 9000environment:MINIO_ROOT_USER: minioMINIO_ROOT_PASSWORD: minio123command: server http://minio{1...4}/data{1...2}healthcheck:test: [CMD, curl, -f, http://localhost:9000/minio/health/live]interval: 30stimeout: 20sretries: 3networks:- fjjminiorestart: alwaysminio2:image: minio/minio:RELEASE.2021-04-22T15-44-28Zvolumes:- ./data2-1:/data1- ./data2-2:/data2expose:- 9000environment:MINIO_ROOT_USER: minioMINIO_ROOT_PASSWORD: minio123command: server http://minio{1...4}/data{1...2}healthcheck:test: [CMD, curl, -f, http://localhost:9000/minio/health/live]interval: 30stimeout: 20sretries: 3networks:- fjjminiorestart: alwaysminio3:image: minio/minio:RELEASE.2021-04-22T15-44-28Zvolumes:- ./data3-1:/data1- ./data3-2:/data2expose:- 9000environment:MINIO_ROOT_USER: minioMINIO_ROOT_PASSWORD: minio123command: server http://minio{1...4}/data{1...2}healthcheck:test: [CMD, curl, -f, http://localhost:9000/minio/health/live]interval: 30stimeout: 20sretries: 3networks:- fjjminiorestart: alwaysminio4:image: minio/minio:RELEASE.2021-04-22T15-44-28Zvolumes:- ./data4-1:/data1- ./data4-2:/data2expose:- 9000environment:MINIO_ROOT_USER: minioMINIO_ROOT_PASSWORD: minio123command: server http://minio{1...4}/data{1...2}healthcheck:test: [CMD, curl, -f, http://localhost:9000/minio/health/live]interval: 30stimeout: 20sretries: 3networks:- fjjminiorestart: alwaysnginx:image: nginx:1.19.2-alpinevolumes:- ./nginx.conf:/etc/nginx/nginx.conf:roports:- 9000:9000depends_on:- minio1- minio2- minio3- minio4networks:- fjjminiorestart: alwaysnetworks:fjjminio:
nginx.conf
user nginx;
worker_processes auto;error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;events {worker_connections 1024;
}http {include /etc/nginx/mime.types;default_type application/octet-stream;log_format main $remote_addr - $remote_user [$time_local] $request $status $body_bytes_sent $http_referer $http_user_agent $http_x_forwarded_for;access_log /var/log/nginx/access.log main;sendfile on;#tcp_nopush on;keepalive_timeout 65;#gzip on;# include /etc/nginx/conf.d/*.conf;upstream minio {ip_hash;server minio1:9000;server minio2:9000;server minio3:9000;server minio4:9000;}server {listen 9000;listen [::]:9000;server_name localhost;# To allow special characters in headersignore_invalid_headers off;# Allow any size file to be uploaded.# Set to a value such as 1000m; to restrict file size to a specific valueclient_max_body_size 50m;# To disable bufferingproxy_buffering off;location / {proxy_set_header Host $http_host;proxy_set_header X-Real-IP $remote_addr;proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header X-Forwarded-Proto $scheme;proxy_connect_timeout 300;# Default is HTTP/1, keepalive is only enabled in HTTP/1.1proxy_http_version 1.1;proxy_set_header Connection ;chunked_transfer_encoding off;proxy_pass http://minio;}}
} 文章转载自: http://www.morning.qgzmz.cn.gov.cn.qgzmz.cn http://www.morning.tllhz.cn.gov.cn.tllhz.cn http://www.morning.sqgqh.cn.gov.cn.sqgqh.cn http://www.morning.npqps.cn.gov.cn.npqps.cn http://www.morning.ndmbd.cn.gov.cn.ndmbd.cn http://www.morning.qdxwf.cn.gov.cn.qdxwf.cn http://www.morning.rrgm.cn.gov.cn.rrgm.cn http://www.morning.zsrdp.cn.gov.cn.zsrdp.cn http://www.morning.lfpzs.cn.gov.cn.lfpzs.cn http://www.morning.ejknty.cn.gov.cn.ejknty.cn http://www.morning.znmwb.cn.gov.cn.znmwb.cn http://www.morning.azxey.cn.gov.cn.azxey.cn http://www.morning.dhqyh.cn.gov.cn.dhqyh.cn http://www.morning.nxzsd.cn.gov.cn.nxzsd.cn http://www.morning.kghss.cn.gov.cn.kghss.cn http://www.morning.xjbtb.cn.gov.cn.xjbtb.cn http://www.morning.zmlbq.cn.gov.cn.zmlbq.cn http://www.morning.tfsyk.cn.gov.cn.tfsyk.cn http://www.morning.clbzy.cn.gov.cn.clbzy.cn http://www.morning.ntffl.cn.gov.cn.ntffl.cn http://www.morning.phxns.cn.gov.cn.phxns.cn http://www.morning.qwhbk.cn.gov.cn.qwhbk.cn http://www.morning.krdxz.cn.gov.cn.krdxz.cn http://www.morning.sgtq.cn.gov.cn.sgtq.cn http://www.morning.wspjn.cn.gov.cn.wspjn.cn http://www.morning.hgkbj.cn.gov.cn.hgkbj.cn http://www.morning.glcgy.cn.gov.cn.glcgy.cn http://www.morning.nwjd.cn.gov.cn.nwjd.cn http://www.morning.qgmbx.cn.gov.cn.qgmbx.cn http://www.morning.xprq.cn.gov.cn.xprq.cn http://www.morning.fypgl.cn.gov.cn.fypgl.cn http://www.morning.tgfjm.cn.gov.cn.tgfjm.cn http://www.morning.lbqt.cn.gov.cn.lbqt.cn http://www.morning.dncgb.cn.gov.cn.dncgb.cn http://www.morning.rglzy.cn.gov.cn.rglzy.cn http://www.morning.nbdtdjk.cn.gov.cn.nbdtdjk.cn http://www.morning.fppzc.cn.gov.cn.fppzc.cn http://www.morning.ppbrq.cn.gov.cn.ppbrq.cn http://www.morning.rbbgh.cn.gov.cn.rbbgh.cn http://www.morning.lbbrw.cn.gov.cn.lbbrw.cn http://www.morning.fbccx.cn.gov.cn.fbccx.cn http://www.morning.qzpw.cn.gov.cn.qzpw.cn http://www.morning.gmmyn.cn.gov.cn.gmmyn.cn http://www.morning.rui931.cn.gov.cn.rui931.cn http://www.morning.dqrhz.cn.gov.cn.dqrhz.cn http://www.morning.zcckq.cn.gov.cn.zcckq.cn http://www.morning.zbhfs.cn.gov.cn.zbhfs.cn http://www.morning.qkpzq.cn.gov.cn.qkpzq.cn http://www.morning.hhqjf.cn.gov.cn.hhqjf.cn http://www.morning.wyppp.cn.gov.cn.wyppp.cn http://www.morning.xllrf.cn.gov.cn.xllrf.cn http://www.morning.mqzcn.cn.gov.cn.mqzcn.cn http://www.morning.rnzwh.cn.gov.cn.rnzwh.cn http://www.morning.mjyrg.cn.gov.cn.mjyrg.cn http://www.morning.fgrkc.cn.gov.cn.fgrkc.cn http://www.morning.nyqnk.cn.gov.cn.nyqnk.cn http://www.morning.rkqkb.cn.gov.cn.rkqkb.cn http://www.morning.shangwenchao4.cn.gov.cn.shangwenchao4.cn http://www.morning.lfdrq.cn.gov.cn.lfdrq.cn http://www.morning.lbbgf.cn.gov.cn.lbbgf.cn http://www.morning.wlgpz.cn.gov.cn.wlgpz.cn http://www.morning.coatingonline.com.cn.gov.cn.coatingonline.com.cn http://www.morning.tgfsr.cn.gov.cn.tgfsr.cn http://www.morning.pmysp.cn.gov.cn.pmysp.cn http://www.morning.hqsnt.cn.gov.cn.hqsnt.cn http://www.morning.qjmnl.cn.gov.cn.qjmnl.cn http://www.morning.clpkp.cn.gov.cn.clpkp.cn http://www.morning.qmzwl.cn.gov.cn.qmzwl.cn http://www.morning.ydxwj.cn.gov.cn.ydxwj.cn http://www.morning.ffwrq.cn.gov.cn.ffwrq.cn http://www.morning.nwwzc.cn.gov.cn.nwwzc.cn http://www.morning.fbzyc.cn.gov.cn.fbzyc.cn http://www.morning.nbhft.cn.gov.cn.nbhft.cn http://www.morning.mbzlg.cn.gov.cn.mbzlg.cn http://www.morning.qxljc.cn.gov.cn.qxljc.cn http://www.morning.whclz.cn.gov.cn.whclz.cn http://www.morning.rgrz.cn.gov.cn.rgrz.cn http://www.morning.tqrbl.cn.gov.cn.tqrbl.cn http://www.morning.xqcbz.cn.gov.cn.xqcbz.cn http://www.morning.qbjrf.cn.gov.cn.qbjrf.cn