-
Notifications
You must be signed in to change notification settings - Fork 476
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to set permissions on files? #407
Comments
All objects by default are uploaded as private on putObject. To make an object public, you would use Set Bucket Policy API explicitly. For golang we have implemented the bucket policy API https://github.com/minio/minio-go/blob/master/API.md#SetBucketPolicy |
I need it in the java api. Would be great if you add this setting. |
Sure, on it :) |
Any ideas when this will be available? |
Right now all of us are working on the stable release of the server. Once we get that out (one week from now), we will start working this API as priority. |
@danyaljj expect it this week. We're documenting and testing now. |
Some clarification: I wonder how they match to what I want. What I want is:
Now what is not clear is how I can use the existing policies (readOnly, writeOnly, etc) to simulate the above two behavior; any ideas? |
By default all objects are private.
Normally publicly available objects are kept inside a prefix as 'public' all you have to do now is setBucketPolicy(bucket, "public", BucketPolicy.ReadOnly)
|
Thanks for clarifying it; two other questions;
|
A statement is a representation of the policies you have it is a standardized format published by AWS S3. http://docs.aws.amazon.com/AmazonS3/latest/dev/example-bucket-policies.html
Any object prefix, "public" is just as an example. For example you can have
why is that? "my-objectname" is just a placeholder you can name it whatever you feel like. |
Just to make sure I understand: setting the |
Bucket policies are quite elaborate from what S3 implements, what is provided with minio-java is a more consumable variant by trimming down the details to bare minimal. Setting a bucket policy in this form.
|
I think |
We haven't made one, because there are some more changes which are pending @balamurugana is working on it. |
Is it possible to make an object private and another one public? (like accessible by anonymous)? (at the time of putting object with
putObject
)The text was updated successfully, but these errors were encountered: