Last active
March 19, 2025 06:52
-
-
Save Nurlan199206/21b8969d5484c9e421606b994fb20f93 to your computer and use it in GitHub Desktop.
minio standalone
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=======================================================systemd============================================================== | |
[Unit] | |
Description=MinIO | |
Documentation=https://docs.min.io | |
Wants=network-online.target | |
After=network-online.target | |
AssertFileIsExecutable=/usr/local/bin/minio | |
[Service] | |
WorkingDirectory=/usr/local/bin/ | |
User=minio-user | |
Group=minio-user | |
ProtectProc=invisible | |
EnvironmentFile=-/etc/default/minio | |
ExecStartPre=/bin/bash -c "if [ -z \"${MINIO_VOLUMES}\" ]; then echo \"Variable MINIO_VOLUMES not set in /etc/default/minio\"; exit 1; fi" | |
ExecStart=/usr/local/bin/minio server $MINIO_OPTS $MINIO_VOLUMES | |
# Let systemd restart this service always | |
Restart=always | |
# Specifies the maximum file descriptor number that can be opened by this process | |
LimitNOFILE=65536 | |
# Specifies the maximum number of threads this process can create | |
TasksMax=infinity | |
# Disable timeout logic and wait until process is stopped | |
TimeoutStopSec=infinity | |
SendSIGKILL=no | |
[Install] | |
WantedBy=multi-user.target | |
===========================================================/etc/default/minio=============================================== | |
MINIO_VOLUMES="/opt/data" | |
MINIO_ACCESS_KEY="minio" | |
MINIO_SECRET_KEY="test" | |
MINIO_OPTS="--address 10.160.2.56:9000" | |
============================================================nginx-console==================================================== | |
upstream console { | |
server 192.168.200.178:9001; | |
} | |
server { | |
listen 443 ssl; | |
listen [::]:443 ssl; | |
server_name minio-console.galamatdev.com; | |
ssl_certificate /etc/letsencrypt/live/galamatdev.com-0001/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/galamatdev.com-0001/privkey.pem; | |
ignore_invalid_headers off; | |
client_max_body_size 0; | |
proxy_buffering off; | |
proxy_request_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_set_header X-NginX-Proxy true; | |
real_ip_header X-Real-IP; | |
proxy_connect_timeout 300; | |
proxy_http_version 1.1; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_set_header Connection "upgrade"; | |
chunked_transfer_encoding off; | |
proxy_pass http://console; | |
} | |
} | |
===================================================== nginx-minio-API =============================================== | |
server { | |
listen 443 ssl; | |
server_name minio-qos.galamatdev.com; | |
ssl_certificate /etc/letsencrypt/live/galamatdev.com-0001/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/galamatdev.com-0001/privkey.pem; | |
location / { | |
proxy_pass http://192.168.200.178:9000; | |
proxy_set_header Host $host; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_set_header Host $host; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-Host $host; | |
proxy_set_header X-Forwarded-Proto $scheme; | |
proxy_buffering off; | |
proxy_request_buffering off; | |
client_max_body_size 0; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment