your container running the web server and php-fpm should only need to be deployed once. the point of PHP is that to update your code you just... replace the file. this sounds like a poorly designed CI pipeline that is of no fault of PHP.
What? There was no CI involved. It's more a matter of being able to spin up separate environments for different teams, projects, or especially clients. Both for security and billing and resource allocation etc.