What's the sites directory structure? Need to Remove EFS Dependency

We’re trying to remove the EFS Dependency within ERPNext so that we can deploy the different sites as ephemeral sites within any bench containers as required to reduce our cost. It would also help us in making any migrations in infrastructure seamless. Towards that, According to this discussion. I saw, the only place where the EFS is required is for sites directory. Towards this, we would like to know the directory structure of the sites folder and what’s the use of each directory. If this pans out, we would be making this an open source app, so I’m open to collaborate in case somebody is interested.

Some thoughts on what files I’ve been able to debug so far the uses of:

  1. Change filelocks to redis lock as we already use redis.
  2. Changing Private and Public files to AWS using the already existing S3 App. We would be making changes to proxy requests through CDN with this instead of directly fetching and sending files to reduce S3 access costs.