Not Permitted Exception could not create path

Getting OCP\Files\NotPermittedException",“Message”:"Could not create path

error while setting S3 as primary storage, works fine if I setup S3 as external storage but when I try to convert it to be primary storage the problems starts

Server: Digital Ocean, Ubuntu 18.0.4, NC - 18.0.3, clean installation, MariaDB, PHP 7.2, Apache

AAAAA{"reqId":"BjBmcdzxhoa55EqubIB7", "level":3,"time":"2020-04-02T16:51:12+00:00","remoteAddr":"89.64.79.191","user":"test","app":"core","method":"GET","url":"/index.php/apps/files/","message": {"Exception":"OCP\\Files\\NotPermittedException","Message":"Could not create path","Code":0, "Trace":[{"file":"/var/www/html/lib/private/Files/SimpleFS/SimpleFolder.php","line":84, "function":"newFile","class":"OC\\Files\\Node\\Folder","type":"->","args":["merged-template-prepend.js"]}, {"file":"/var/www/html/lib/private/Template/JSCombiner.php","line":179, "function":"newFile","class":"OC\\Files\\SimpleFS\\SimpleFolder","type":"->","args": ["merged-template-prepend.js"]},AAAA

I created objectstorage.config.php and setup nextcloud

config.php
AAA $CONFIG = array ( 'instanceid' => '', 'passwordsalt' => '', 'secret' => '', 'trusted_domains' => array ( 0 => '', ), 'datadirectory' => '/var/www/html/data', 'dbtype' => 'mysql', 'version' => '18.0.3.0', 'overwrite.cli.url' => '', 'dbname' => '', 'dbhost' => 'localhost', 'dbport' => '', 'dbtableprefix' => 'oc_', 'dbuser' => '', 'dbpassword' => '', 'installed' => true, 'maintenance' => false, 'objectstore' => array ( 'class' => '\\OC\\Files\\ObjectStore\\S3', 'arguments' => array ( 'bucket' => 'nextcloud', 'autocreate' => true, 'key' => '', 'secret' => '', 'hostname' => 's3.us-east-2.amazonaws.com', 'use_ssl' => false, 'region' => 'us-east-2', 'use_path_style' => false, ), ), ); AAA

I checked my permissions and thy r 750 and www:data all aligned properly.

Any pointers would be helpful
Thanks