Minio is an object storage server built for cloud applications and DevOps. Minio is S3 compatible and provides an open source alternative to AWS S3. You can download and install Minio pretty quickly. Minio also provides an official Docker image. For further details, check out Minio documentation website.

AccessKey and SecretKey

Once you install and deploy Minio server, you can get the AccessKey and SecretKey from the startup message.

2017-01-24T19:53:21.141730078Z Endpoint:
2017-01-24T19:53:21.141735582Z AccessKey: 5fD3434325fDaGE77BNJlSoV1xGp
2017-01-24T19:53:21.141738933Z SecretKey: Quie2teech4oofoo9Dahsoo7aithauja
2017-01-24T19:53:21.141742292Z Region:    us-east-1
2017-01-24T19:53:21.141745405Z SQS ARNs:  <none>
2017-01-24T19:53:21.141752499Z Browser Access:
2017-01-24T19:53:21.141762000Z Command-line Access: https://docs.minio.io/docs/minio-client-quickstart-guide
2017-01-24T19:53:21.141765638Z    $ mc config host add myminio 1H2MI5BCU45990DZ3WRL flJlSoV1xGp+u2fhfDaGE77BNE6OdyvAsdI15kPq
2017-01-24T19:53:21.141771631Z Object API (Amazon S3 compatible):
2017-01-24T19:53:21.141774638Z    Go:         https://docs.minio.io/docs/golang-client-quickstart-guide
2017-01-24T19:53:21.142003548Z    Java:       https://docs.minio.io/docs/java-client-quickstart-guide
2017-01-24T19:53:21.142019474Z    Python:     https://docs.minio.io/docs/python-client-quickstart-guide
2017-01-24T19:53:21.142024004Z    JavaScript: https://docs.minio.io/docs/javascript-client-quickstart-guide
2017-01-24T19:53:21.142030994Z Drive Capacity: 262 GiB Free, 303 GiB Total

To override Minio auto-generated keys, you may pass secret and access keys explicitly as environment variables. Find more details here.

Setup Rocket.Chat to use Minio

To setup Minio as the file storage server in Rocket.Chat, go to File Uploads section under Administration, then set Storage Type: GridFS (default) to AmazonS3. Next, access the AmazonS3 menu and update the following details:

Configuration Name Description
Bucket name Minio Bucket Name
Access Key Minio server Access Key
Secret Key Minio server Secret Access Key
Region us-east-1
Bucket URL http://[your.minio.domain/bucketname]
Signature Version v2 (This may not be needed if using ssl)
Force Path Style true (this may not be needed if using ssl)
URLs expiration time 0 (if you want that your files don’t have an expiry date)

Set up Production

In production, you can use a reverse proxy with Minio server. Check out the documentation for Nginx, Apache and Apache2.

You can secure access to Minio server with TLS. Check out the documentation here.

Note: If you specify a different region in Minio, make sure it is the same as the S3 region. Find a full list of regions here.