This message was deleted.
# general
s
This message was deleted.
b
Hi @clever-lawyer-94920 That would use the Terraform provisioner that effectively connects to the instance and runs commands. Pulumi doesn't (at this time) have the same corresponding command BUT as Pulumi is built on the language runtimes, you can import the correct ssh package and connect to the machine in the same way
c
when I said provisioning i meant creating/spinning up the infra.
As in terraform is a provisioning tool and ansible is configuration management tool, would you agree. They excel at each of these different jobs. Does Pulumi do both Or is it more like terraform, a provisioning tool?
Oh, ok. I got it. Pulumi is a infrastructure provisioning tool and for configuration management I will have to use some other tool like Ansible, am I right?
b
@clever-lawyer-94920 yes, I would separate the work
👍 1
b
just to throw my 2c in here, Pulumi doesn't do anything at the OS layer, if you want to do configuration management at the OS layer you will have to use ansible
👍 1
p
are there any plans to provide some kind of components to ease the use of such a tool together with pulumi?
b
i don't believe there's anything on the roadmap
b
If you really wanted to use Pulumi for this, we have an example of setting up a provisioner and updating code, but a dedicated tool like ansible would be better. https://www.github.com/pulumi/examples/tree/master/aws-ts-ec2-provisioners (I wouldn't recommend it though)
p
I agree, but what I would like to have is some kind of an integration between the two tools
b
Just out of question, how would you see that working? Pulumi talks to the provider (say AWS) rather than the individual machine. You could use userdata to run a playbook, although I'd probably build an AMI that was pre-setup and use that. You could use that provisioner pattern that I linked to to build an ec2 instance, add whatever configuration you'd want, then build an AMI from that instance. You'd probably need to use automation API for that as you'd want to stop the instance (which I don't think you can do with Pulumi) before generating the AMI.
It's doable, but not very nice
p
Yes, your right - I was more thinking about direct support to run scripts e.g. https://github.com/pulumi/pulumi/issues/99 I did actually already use the mentioned provisioner implementation, But direct/native support would definitely be preferred and ease our code base a lot.