feat: add minio (#161)

* feat: add minio

* fix: minio's reverse proxy

* fix: minio secrets & reverse proxy
This commit is contained in:
Ryan Yin
2024-09-02 18:28:56 +08:00
committed by GitHub
parent 2ff2c56fae
commit 07b74cd2e5
4 changed files with 58 additions and 3 deletions
+32
View File
@@ -91,6 +91,38 @@ in {
encode zstd gzip
reverse_proxy http://localhost:9093
'';
virtualHosts."minio.writefor.fun".extraConfig = ''
${hostCommonConfig}
encode zstd gzip
reverse_proxy http://localhost:9096 {
header_up Host {http.request.host}
header_up X-Real-IP {http.request.remote.host}
header_up X-Forwarded-For {http.request.header.X-Forwarded-For}
header_up X-Forwarded-Proto {scheme}
transport http {
dial_timeout 300s
read_timeout 300s
write_timeout 300s
}
}
'';
virtualHosts."minio-ui.writefor.fun".extraConfig = ''
${hostCommonConfig}
encode zstd gzip
reverse_proxy http://localhost:9097 {
header_up Host {http.request.host}
header_up X-Real-IP {http.request.remote.host}
header_up X-Forwarded-For {http.request.header.X-Forwarded-For}
header_up X-Forwarded-Proto {scheme}
header_up Upgrade {http.request.header.Upgrade}
header_up Connection {http.request.header.Connection}
transport http {
dial_timeout 300s
read_timeout 300s
write_timeout 300s
}
}
'';
};
networking.firewall.allowedTCPPorts = [80 443];