Wordpress on AWS, how to update only a theme In order to setup a flow from developer code to a public URL, I've been testing some flows and the current one does not work that good:

I have an AWS Pipeline that picks up the source code from CodeCommit, builds the Sage Theme using gulp and deploys the entire code into an Elacticbeanstalk application.

The bad part here is that I'm pushing the entire code again and again, all I really need is the theme folder. Plus, I need to re-activate all plugins every single time :(

What is the best approach for such scenario?
I'm not terribly familiar with elastic beanstalk, so I'm not sure if my method is at all approachable with your workflow, but I have a similar (non-AWS) workflow, and I can share how I do it.



I've managed to only push theme changes by separating the deployment of wordpress, and its mysql DB (both as a docker containers, in my case), and the deployment of the themes (which is a git repo).

This way I can separate/automate the deployment of wordpress, mysql, and my wordpress theme in a fairly loosely coupled manner.

Updating consists of only performing a git pull to the themes directory -- No other wordpress/mysql interaction occurs, so my plugins stay in whatever state they were previously in prior to the theme update.