This heavily depends on which user owns the files.
If the webserver is run by www-data and you installed Flarum via a shell user forge (for example), then forge owns the storage folder. Setting 775 will not allow www-data to write in the folder if the users are in different groups. You either need xx7 (world write), or change the ownership of the files, for example sudo chown www-data: storage (if your webserver user is www-data).
Same for assets. Also if you have not yet installed Flarum, it needs to be able to write in the Flarum root folder as well to create config.php.