大网数据广告活动
服务器运维问答

Serving HTTPS images with Minio

· 52CE 我爱测

I followed this documentation , but I can't make my images to be served with HTTPS. I have the following /etc/default/minio configuration file: MINIO_ACCESS_KEY="admin" MINIO_VOLUMES="/usr/local/share/minio/" MINIO_OPTS="-C /etc/…

问题原文

原帖链接 · COil · CC BY-SA 4.0

I followed this documentation, but I can't make my images to be served with HTTPS.

I have the following /etc/default/minio configuration file:

MINIO_ACCESS_KEY="admin"
MINIO_VOLUMES="/usr/local/share/minio/"
MINIO_OPTS="-C /etc/minio --address vps.ovh.net:443 --console-address :9001"
MINIO_SECRET_KEY="secret"

If I specify another port like 9000 instead of 443, this time it works, but the file is served with HTTP:

http://vps.ovh.net:9000/images/product/e53b9fde-4df1-4e54-bef4-76cd8c97cdb2.jpg

I have generated the certificates in /etc/minio :

pwd
/etc/minio/certs
ll
rw------- 1 minio-user minio-user 1704 Feb  3 11:05 private.key
-rw-r--r-- 1 minio-user minio-user 5522 Feb  3 11:05 public.crt

Any ideas or tips?

已采纳解答

原帖链接 · Esa Jokinen · CC BY-SA 4.0

The documentation you referenced advises placing the certificates under ${HOME}/.minio/certs which is the default path. You have not followed the documentation, but placed them under the path /etc/minio/certs, instead.

If you wish to use that path, you would use --certs-dir /etc/minio/certs in your MINIO_OPTS, as documented in both Network Encryption (TLS) (Default Path vs. Custom Path) & MinIO Server --certs-dir, -S.

It seems that with -C /etc/minio you have tried to do this using a deprecated parameter:

Important:

MinIO Server RELEASE.2023-12-09T18-17-51Z removes the deprecated --config-dir | -C parameter. Deployments using this flag may start without TLS enabled. Replace those parameters with --certs-dir | -S and restart to re-enable TLS.

That is exactly what happened.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2024-02-03)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。