-
Notifications
You must be signed in to change notification settings - Fork 289
How to create a custom MinIO image for testing purposes
All started because of this task: https://github.com/miniohq/engineering/issues/441 that I got assigned in order to improve our coverage of this repository. The task is simple if you have KMS enabled in MinIO but that is not the case when I got this task. If you are interested in KMS, I recommend you to read more on the documentation available at: https://docs.min.io/docs/minio-kms-quickstart-guide.html Anyway, the center of this discussion is more on the fact that I wanted to learn how to modify a MinIO Docker Image with the intention of putting KMS on top of it, in this known how document, I will focus in just a simple task, we are going to show how to customize your MinIO image and that will let you go further with any other related task like mine. Ok, without further ado, let's start.
There are several ways in which you can get MinIO
binary. You can either call make all
at minio/minio
repo and get the binary compiled with your machine architecture or you can just download directly from: https://min.io/download#/linux
For this particular example, and since I have an Apple M1 Chip, I will proceed to download from the webpage. The reason is simple, I want to compile for Ubuntu Virtual Machines on our GitHub actions. If by mistake you provide your compiled binary to a different architecture, you are going to get this message below:
/usr/bin/docker-entrypoint.sh: line 24: /opt/bin/minio: cannot execute binary file: Exec format error
/usr/bin/docker-entrypoint.sh: line 24: /opt/bin/minio: Success
That means that you are trying to execute a binary from another architecture and this is not possible. So be careful and select the architecture that matches your Docker Container.