I am running the Atmoz SFTP server in a container and a Go application running in a separate container, with both having the same underlying EBS volume mounted.
When the Go application runs, it creates directories inside the directories served to users via the SFTP application. The problem is the FTP users do not have write permission on those newly created directories.
Part of the issue is the Go application runs as root and new directories are owned by root.
How can I have the Go application create the directories so the users on the other system have write access? How can I create a directory and have it inherit the permissions of it's parent? (The parent is initially created by Atmoz SFTP and has correct permissions)