@@ -13,31 +13,60 @@ setting_up_container
1313network_check
1414update_os
1515
16- msg_info " Setup MinIO"
17- RELEASE=$( curl -fsSL https://api.github.com/repos/minio/minio/releases/latest | grep ' "tag_name"' | awk -F ' "' ' {print $4}' )
18- curl -fsSL " https://dl.min.io/server/minio/release/linux-amd64/minio" -o /usr/local/bin/minio
16+ FEATURE_RICH_VERSION=" 2025-04-22T22-12-26Z"
17+
18+ echo
19+ echo " MinIO recently removed many management features from the Console UI."
20+ echo " The last feature-complete version is: $FEATURE_RICH_VERSION "
21+ echo " Latest versions require the paid edition for full UI functionality."
22+ echo
23+ echo " Choose which version to install:"
24+ echo " [N] Feature-rich community version ($FEATURE_RICH_VERSION ) [Recommended]"
25+ echo " [Y] Latest version (may lack UI features)"
26+ echo
27+ read -p " Install latest MinIO version? [y/N]: " -n 1 -r
28+ echo
29+ if [[ $REPLY =~ ^[Yy]$ ]]; then
30+ USE_LATEST=true
31+ else
32+ USE_LATEST=false
33+ fi
34+
35+ msg_info " Setting up MinIO"
36+ if [[ " $USE_LATEST " == " true" ]]; then
37+ RELEASE=$( curl -fsSL https://api.github.com/repos/minio/minio/releases/latest | grep ' "tag_name"' | awk -F ' "' ' {print $4}' )
38+ DOWNLOAD_URL=" https://dl.min.io/server/minio/release/linux-amd64/minio"
39+ else
40+ RELEASE=" $FEATURE_RICH_VERSION "
41+ DOWNLOAD_URL=" https://dl.min.io/server/minio/release/linux-amd64/archive/minio.RELEASE.${FEATURE_RICH_VERSION} "
42+ fi
43+
44+ curl -fsSL " $DOWNLOAD_URL " -o /usr/local/bin/minio
1945chmod +x /usr/local/bin/minio
2046useradd -r minio-user -s /sbin/nologin
2147mkdir -p /home/minio-user
2248chown minio-user:minio-user /home/minio-user
2349mkdir -p /data
2450chown minio-user:minio-user /data
51+
2552MINIO_ADMIN_USER=" minioadmin"
2653MINIO_ADMIN_PASSWORD=" $( openssl rand -base64 18 | tr -dc ' a-zA-Z0-9' | cut -c1-13) "
54+
2755cat << EOF >/etc/default/minio
2856MINIO_ROOT_USER=${MINIO_ADMIN_USER}
2957MINIO_ROOT_PASSWORD=${MINIO_ADMIN_PASSWORD}
3058EOF
59+
3160{
3261 echo " "
33- echo " MinIO- Credentials"
62+ echo " MinIO Credentials"
3463 echo " MinIO Admin User: $MINIO_ADMIN_USER "
3564 echo " MinIO Admin Password: $MINIO_ADMIN_PASSWORD "
3665} >> ~/minio.creds
37- echo " ${RELEASE} " > /opt/${APPLICATION} _version.txt
66+ echo " ${RELEASE} " > /opt/${APPLICATION,, } _version.txt
3867msg_ok " Setup MinIO"
3968
40- msg_info " Creating Service "
69+ msg_info " Creating service "
4170cat << EOF >/etc/systemd/system/minio.service
4271[Unit]
4372Description=MinIO
@@ -57,13 +86,14 @@ LimitNOFILE=65536
5786[Install]
5887WantedBy=multi-user.target
5988EOF
89+
6090systemctl enable -q --now minio
61- msg_ok " Created Service"
91+ msg_ok " Service created "
6292
6393motd_ssh
6494customize
6595
6696msg_info " Cleaning up"
6797$STD apt-get -y autoremove
6898$STD apt-get -y autoclean
69- msg_ok " Cleaned "
99+ msg_ok " Cleanup complete "
0 commit comments