第一章 MinIO介绍与安装
MinIO是一个高性能对象存储方案,支持分布式部署,它的API可以与 Amazon S3
云存储服务兼容。
安装MinIO
为了简单的学习 MinIO
,这里通过Docker的方式来安装。对于生产环境,官方推荐使用集群的方式来安装。
docker run \
-p 9000:9000 \
-p 9001:9001 \
-e "MINIO_ROOT_USER=minio" \
-e "MINIO_ROOT_PASSWORD=minio12345" \
quay.io/minio/minio server /data --console-address ":9001"
启动成功后,控制台会打印 API
(endpoint) 的地址和 console
地址。
WARNING: Detected Linux kernel version older than 4.0.0 release, there are some known potential performance problems with this kernel version. MinIO recommends a minimum of 4.x.x linux kernel version for best performance
API: http://172.17.0.2:9000 http://127.0.0.1:9000
Console: http://172.17.0.2:9001 http://127.0.0.1:9001
Documentation: https://docs.min.io
Maven依赖
<dependency>
<groupId>io.minio</groupId>
<artifactId>minio</artifactId>
<version>8.3.7</version>
</dependency>
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId>
<version>4.9.0</version>
</dependency>
YML配置
minio:
endpoint: http://172.17.0.2:9000