Read/Create/Delete files in "files" (755) folder

Hi all,

The permission of files folder is 755 , Shopware can create files (invoices) in folder files/documents/ and let admin download those files.

My question is: how can I gain the permission to do the same thing, that mean open/create/delete files in this folder with admin account ofcourse.

I tried

$filesystem = $this->container->get(‘shopware.filesystem.private’);

$filesystem->write(“abc.txt”,“abc”);

but no luck.

Should I change permission of this folder to 777 ?

Thanks!