Hi
In your minio shopping app demo you create a public link to the image. I have copied this line of code and tried this with my minio installation and I get an access denied error.
var publicUrl = minioClient.protocol + '//' + minioClient.host + ':' + minioClient.port + '/' + minioBucket + '/' + obj.name
I would expect to see the image in the browser when accessing the url.
I get the following error:
<?xml version="1.0" encoding="UTF-8"?>
<Error>
<Code>AccessDenied</Code>
<Message>Access Denied.</Message>
<Key></Key>
<BucketName></BucketName>
<Resource>/testbucket/IMG_0278.JPG</Resource>
<RequestId>3L137</RequestId>
<HostId>3L137</HostId>
</Error>
brew install miniobrew services start minio (fix the .plist file before ;))var stream = minioClient.listObjects(minioBucket,'', true)
stream.on('data', function(obj) {
// Lets construct the URL with our object name.
var publicUrl = minioClient.protocol + '//' + minioClient.host + ':' + minioClient.port + '/' + minioBucket + '/' + obj.name
console.log(publicUrl);
});
I was trying to load a file through the browser, like you do in the shopping app demo.
What could this be? Do I have to change something?
Thanks
Never mind, I found it. 馃槉
For those having the same issue, either use the command line client to set the policy for the bucket to public, more here, or use the web interface, where you click on the three dots next to the bucket name and add a row with the prefix * and Read and Write permissions.
It was a sad day once i got threw access denied
i got the same issue even though i set public permission for the bucket
Never mind, I found it.
For those having the same issue, either use the command line client to set the policy for the bucket to public, more here, or use the web interface, where you click on the three dots next to the bucket name and add a row with the prefix
*andRead and Writepermissions.
@iamso how to do this same but from mc cli?
Most helpful comment
Never mind, I found it. 馃槉
For those having the same issue, either use the command line client to set the policy for the bucket to public, more here, or use the web interface, where you click on the three dots next to the bucket name and add a row with the prefix
*andRead and Writepermissions.