<@UEDJHEH71> what are you trying to accomplish?
# general
b
@straight-guitar-55156 what are you trying to accomplish?
s
Patching software (updating software versions). That would involve getting list of the hosts and what versions are running on them (for the least)
b
ok, is this software running on ec2 or containers?
s
Mainly ec2
b
are these ec2 instances ephemeral?
s
There are bunch of software that are running on ec2 instances, across multiple regions and accounts. So, I would wanna first get the list of all those hosts and list of all the software (application, kernel etc), running on them and do software patching (security updates). Similar to dynamic inventory with Ansible.
Most of them aren’t ephemeral, a few of them are, though.
b
pulumi is more geared for ephemeral workloads, thats how it lets you manage everything via code (everything can be destroyed at anytime and recreated)
a tool like
ansible
would be more suited to this usecase
you could write code that scans aws for ec2 instances and generates an inventory file
then have ansible consume that inventory file and perform update logic if necessary
edit: I guess you could use pulumi to get the list of ec2 instances. But then you still couldn’t use it to check kernels and system resources. Unless that stuff is tagged in AWS
s
That’s what we have currently in our system. But as I was reading about Pulumi serving as Infrastructure as Code, I was wondering if it also manages software upgrades or not. We have a quite a number of ec2 instances that are ephemeral but about 50% aren’t.
b
Once you move to an architecture where you can just destroy the instance and replace it with a new AMI then pulumi would come in
or switch userdata to get ansible to pull a different git commit
s
In that case, how would it get me software version?
^ for ephemeral systems
b
it cant
pulumi cant ssh onto the ec2 box
if the ec2 instance is tagged with the application name or version it could do that
but that would imply those tags already exist, which I assume they aren’t
s
Thank you so much @busy-umbrella-36067 ! 🙂