amazon-s3miniokuzzle

Kuzzle S3 plugin / Minio cant connect


I have the following Kuzzle S3 Plugin config:

"s3": {
  // AWS S3 bucket
  "bucketName": "chris",  // this is a bucket i created in Minio
  "endpoint": "http://10.0.0.66:9000",
  "s3ClientOptions": {
    "s3ForcePathStyle": false
  },
  "signedUrlTTL": 1200000,
  "redisPrefix": "s3Plugin/uploads"
},

I don't know if this config is correct. When I use the test file from kuzzleio/kuzzle-plugin-s3/blob/master/test/s3-upload-test.html

I get the following error

Uncaught (in promise) KuzzleError: Caught an unexpected plugin error: Inaccessible host: `chris.10.0.0.66'. This service may not be available in the `us-east-1' region. This is probably not a Kuzzle error, but a problem with a plugin implementation.

'chris.10.0.0.66' is an incorrect resource - as you can see, I'm not referencing this in the config.

enter image description here

The 10.0.0.66 is only accessible in my network.

Can someone help with this? Thank you much.


Solution

  • Ok - so I found a working answer

    "s3": {
      // AWS S3 bucket
      "bucketName": "chris",
      "endpoint": "http://10.0.0.66:9000",
      "s3ClientOptions": {
        "s3ForcePathStyle": true,
        "signatureVersion": "v4"
      },
      "signedUrlTTL": 1200000,
      "redisPrefix": "s3Plugin/uploads"
    },
    

    I modified the s3ClientOptions with: "s3ClientOptions": { "s3ForcePathStyle": true, // must be true for Minio "signatureVersion": "v4" // added this line }

    Source = https://docs.min.io/docs/how-to-use-aws-sdk-for-javascript-with-minio-server.html