Most of our builds are 'basically' Node.js / npm or PHP / composer, so reasonably contained build processes. It looks simple on the surface, but once you start running CI for a while you notice all the dependencies on the environment. Versions installed of PHP, Composer, Node.js, MySQL / MariaDB, Java, Ant all tripped us at some point. (Not to mention we develop on Mac, deploy on Linux.)
Instead, we now have a very basic Ubuntu-based AMI with Docker installed, and otherwise stopped depending on the host environment as much as possible. Jenkins spins up an EC2 instance when needed, and shuts it down again after some period of inactivity. 95% of our pipeline scripts do work inside a container.
Instead, we now have a very basic Ubuntu-based AMI with Docker installed, and otherwise stopped depending on the host environment as much as possible. Jenkins spins up an EC2 instance when needed, and shuts it down again after some period of inactivity. 95% of our pipeline scripts do work inside a container.