当前位置: 首页 > news >正文

手机房产网站模板wordpress竖状导航

手机房产网站模板,wordpress竖状导航,网站开发软件开发,给你一个网站怎么做目录 1. 说明 2. 配置表 3. 步骤 3.1 放行服务端口 3.2 docker-compose 编排 4. 入口反向代理与负载均衡配置 4.1 api入口 4.2 管理入口 5. 用例 6. 参考 1. 说明 以多节点的Docker容器方式实现minio存储集群#xff0c;并配以nginx反向代理及负载均衡作为访问入口。…目录 1. 说明 2. 配置表 3. 步骤 3.1 放行服务端口 3.2 docker-compose 编排 4. 入口反向代理与负载均衡配置 4.1 api入口 4.2 管理入口 5. 用例 6. 参考 1. 说明 以多节点的Docker容器方式实现minio存储集群并配以nginx反向代理及负载均衡作为访问入口。 2. 配置表 服务器 (2 nodes) ip备注center01.dev.sb172.16.20.20 Minio 入口http://minio01.dev.sb 管理入口 http://minio01-console.dev.sb 硬件配置8核16G2T 软件配置ubuntu22.04 宝塔面板 nginx node1172.16.20.10... 3. 步骤 3.1 放行服务端口 - 90009001 3.2 docker-compose 编排 services:minio:image: minio/minio:latestcontainer_name: minio-node1hostname: minio{x}expose:- 9000- 9001environment:- MINIO_ROOT_USERadmin- MINIO_ROOT_PASSWORDyou knowvolumes:- /data0/Server/Db/minio/data0:/data0- /data0/Server/Db/minio/data1:/data1command: server --console-address :9001 --address :9000 http://minio{0...1}/data{0...1}privileged: truehealthcheck:test: [CMD, curl, -f, http://localhost:9000/minio/health/live]interval: 30stimeout: 20sretries: 3extra_hosts:- minio0:172.16.20.10- minio1:172.16.20.20restart: alwaysnetwork_mode: host4. 入口反向代理与负载均衡配置 4.1 api入口 server {listen 80;listen [::]:80;server_name minio01.dev.sb;# 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 0;# Disable bufferingproxy_buffering off;proxy_request_buffering off;location / {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_set_header Host $http_host;proxy_cache_convert_head off;proxy_cache_key $scheme$proxy_host$uri$is_args$args|$request_body;proxy_read_timeout 300s;proxy_connect_timeout 75s;proxy_http_version 1.1;proxy_set_header Connection ;chunked_transfer_encoding on;proxy_redirect off;proxy_pass http://minio_s3; # This uses the upstream directive definition to load balance} }upstream minio_s3 {server 172.16.20.10:9000 weight5;server 172.16.20.20:9000 weight1; } 4.2 管理入口 server {listen 80;listen [::]:80;server_name minio01-console.dev.sb;# 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 0;# Disable bufferingproxy_buffering off;proxy_request_buffering off;location / {rewrite ^/minio/ui/(.*) /$1 break;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_set_header X-NginX-Proxy true;# This is necessary to pass the correct IP to be hashedreal_ip_header X-Real-IP;proxy_connect_timeout 300;# To support websockets in MinIO versions released after January 2023proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection upgrade;# Some environments may encounter CORS errors (Kubernetes Nginx Ingress)# Uncomment the following line to set the Origin request to an empty string# proxy_set_header Origin ;chunked_transfer_encoding off;proxy_pass http://minio_console; # This uses the upstream directive definition to load balance} }upstream minio_console {server 172.16.20.10:9001;server 172.16.20.20:9001; } 5. 用例 from minio import Minio from minio.error import S3Errordef main():# 创建 MinIO 客户端实例client Minio(# 172.16.20.10:9000, # MinIO 服务器地址和端口minio01.dev.sb, # MinIO 服务器地址和端口access_keymy key, # 替换为你的 MinIO 访问密钥secret_keyyou know it, # 替换为你的 MinIO 秘密密钥secureFalse, # 使用 False 如果是 HTTP 而非 HTTPS)# 创建一个名为 mybucket 的存储桶bucket_name mybucketif not client.bucket_exists(bucket_name):client.make_bucket(bucket_name)else:print(fBucket {bucket_name} already exists)# 上传文件file_path D:/Temp/demo/videos/acfa586c0b3248ec95df81267a767258.mp4object_name acfa586c0b3248ec95df81267a767258.pngclient.fput_object(bucket_name, object_name, file_path)print(f{file_path} is successfully uploaded as object {object_name} to bucket {bucket_name}.)# 下载文件client.fget_object(bucket_name, object_name, D:/Temp/tmp10/a2.mp4)print(f{object_name} is successfully downloaded.)# 列出存储桶中的对象objects client.list_objects(bucket_name)for obj in objects:print(obj.object_name)# 删除文件# client.remove_object(bucket_name, object_name)# print(f{object_name} is successfully deleted.)if __name__ __main__:try:main()except S3Error as exc:print(error occurred., exc)如图 6. 参考 - Stat: Access Denied for Minio S3 Bucket behind Nginx Reverse Proxy with https enabled · Issue #4860 · restic/restic · GitHub - Deploy MinIO: Multi-Node Multi-Drive — MinIO Object Storage for Linux
http://www.hkea.cn/news/14593299/

相关文章:

  • jsp可以做网站吗ui网页设计师职责能力
  • 开发网站app公司佛山网站建设百家号
  • 如何做企业网站推广产品百度推广关键词查询
  • 企业做网站有用吗天涯个人主页哪个网站好
  • 南昌中小企业网站制作国外服务器vps
  • 上饶网站建设公司网页制作模板及素材
  • 特克斯与凯科斯群岛域名官方网站营销号是啥意思
  • 网站icp备案怎么查询免费的舆情网站入口有哪些
  • wordpress知名网站做网站买域名就行了吗
  • 网站建设是什么行业内部券网站怎么做
  • 对二次网站开发的认识网站建设销售是什么
  • 晋安网站建设linux下载wordpress
  • node 做的网站后端网站建设那家好
  • 上海企业网站建设方案网站推广怎么推
  • 郑州购物网站建设网站建设邀标书
  • 易联网站建设wordpress小兽
  • 做跨国婚恋网站赚钱吗网站手机模板源码下载
  • 网站建设与开发专业网页制作技巧
  • 哪个网站有学做吃的网页加速器免费版
  • 网站建设公司如何推广中国e网网站建设
  • 海北营销网站建设公司广州网站建设网站优化推广
  • 网站建设添加展示栏qq开放平台
  • 网站被加入js广告自己做网站可以随便起名字吗
  • 收费网站开发wordpress 图片旋转代码
  • 同城信息商家的网站开发网站建设找翰诺
  • 学做网站看什么书免费可商用素材网站
  • 做石油期货看什么网站网站宣传虚假处罚标准
  • 电子商务网站建设与管理考试广州热点新闻
  • 广西建设厅官方网站怎样制定一个网站建设方案
  • 医疗知识普及网站开发杭州滨江的网站建设公司