We have a custom python tool that does something similar, except for terraform and kubectl. This is the sort of thing where you probably have to write it from scratch to match your workflow, but it should end up ~500 LOC in your favorite scripting language.
Then we wrap that tool in jenkin pipelines so we can easily trigger it in response to events like code being pushed.