backup/backup

Storage configuration for Minio (S3)

lksnmnn opened this issue · 3 comments

What went wrong?

I've spend roughly 3 hours to get this gem working with Minio via the S3 interface.
This issue is meant as documentation for future reference and can be closed.

Error message

Excon::Error::Socket: getaddrinfo: No address associated with hostname (SocketError)

How is your copy of backup configured?

Here is the S3 storage configuration which finally worked.

    store_with S3 do |s3|
        s3.access_key_id = "your access key id"
        s3.secret_access_key = "your access key"
        s3.bucket = "bucket_name"
        s3.fog_options = {
          host: "minio_host",
          port: "minio_port",
          scheme: "minio_scheme", # http / https
          aws_signature_version: 4,
          path_style: true 
        }
    end

Edit: I'll add the two things that went wrong:

  1. You can't use the fog_option endpoint for anything else than normal http/https ports (i.e., 80/443), so if you run minio without a proxy (e.g. in Docker), the default port 9000 does not work. But you can work around that by specifying host, port and scheme separetly.
  2. If your minio setup is not able to resolve "bucket.host" (as per default settings) you need to add path_style: true which I luckily read in another issue.

These two points should be added to the documentation.

Cheers,
Lukas

Thanks @lksnmnn for the contribution.

Would you be so kind as to send us a small PR to the official documentation ? in the S3 page ?

Added the PR: #965

It took me a while to find where docs reside ^^.

Thanks for the PR.

Closing now