AWS Elastic Beanstalk

ErichMosier

New Member
I am setting up Mailwizz on an AWS Elastic Beanstalk instance. I am wondering if there are files written to folders during the installation process, and if so what and where they are.

The problem I am running into is that I go through the installation process on the production server, but when I upload new updates from the dev environment, everything appears to be wiped out and I have to reinstall.

With Elastic Beanstalk, in case you don't know, all of the code gets replaced every time you do an update. So if there are files that are being created during installation on production, they will all get overwritten when I upload a new batch of changes from dev. So unless I know what the files are and where they are, so I can download them to my dev environment , I wont be able to make them part of my code base.

Or is there another way to handle this? I couldn't find anything in the forums related to this so maybe it hasn't come up before.
 
@ErichMosier - Mailwizz creates a single file during install, that is apps/common/config/main-custom.php
Then, it makes some folder writable, but there is a bash script that comes with mailwizz which you can make executable and call to make the folders writable. The bash script location is apps/console/commands/shell/set-dir-perms.
That's pretty much it.
 
Why are the folders writable? Is content saved to these folders and if so how would this affect a load balanced installation?
 
I assume if the cache is missing it will be regenerated, so in this way each server will have it's own cache.

In terms of templates and "much more", could this be handled through your S3 extension so that files are stored there instead of in the file system?
 
I assume if the cache is missing it will be regenerated, so in this way each server will have it's own cache.
That's correct, but also you can use Redis/Memcached for caching, so you can avoid this issue.(see Yii's docs related to this)

In terms of templates and "much more", could this be handled through your S3 extension so that files are stored there instead of in the file system?
Part of it yes, i mean the email assets will be stored there so a huge problem goes away.

Another thing to keep in mind is that if you're using queue imports, then when the file to be imported is uploaded, is moved inside the apps/common/runtime directory, so such edge cases depend entirely on you and the way you'll choose to handle this.
 
Back
Top