-
Notifications
You must be signed in to change notification settings - Fork 130
How to set s3 file acl to public-read after upload? #259
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
Comments
Hi @winds1983, You can override Configuration reader class, and replace $filesystem = new Filesystem(new AwsS3v3($client, $opt['aws_s3_v3']['bucket_name'], $opt['aws_s3_v3']['optional_prefix'])); with something like this $filesystem = new Filesystem(new AwsS3v3($client, $opt['aws_s3_v3']['bucket_name'], $opt['aws_s3_v3']['optional_prefix']), [
'visibility' => AdapterInterface::VISIBILITY_PRIVATE
]); More information here: Global visibility setting |
@helios-ag ok, thanks, I will try this. |
@winds1983 if it will work for you, this feature can be implemented into bundle. |
@helios-ag Hi, i have the same issue, so i try to change ElFinderConfigurationReader.php $filesystem = new Filesystem(new AwsS3v3($client, $opt['aws_s3_v3']['bucket_name'], $opt['aws_s3_v3']['optional_prefix']), [ 'visibility' => AdapterInterface::VISIBILITY_PUBLIC ]); With that, my uploaded objects are public. |
The workaround does not work, if caching is on. Turn off flysystems filesystem cache to make it work. See barryvdh/elfinder-flysystem-driver#73 Tested with version 9.1 |
Please have a look at #365 |
Issue Type:
Bundle Version:
Master or exact version, i.e. 6.0.1
Summary:
Below settings are my config, but it cannot set s3 file ACL. in other words, I still get private ACL after upload file, how to set it? I use Flysystem aws v3
The text was updated successfully, but these errors were encountered: