https://pulumi.com logo
#general
Title
# general
b

bulky-policeman-29913

11/24/2021, 6:33 PM
Does pulumi have the concept of a plugin that could be ran as say a pre-step to pulumi up? I know plugins/resource providers are there from that perspective, but it would be nice to consolidate some canned capabilities inside a plugin vs performing builds/dependency installs outside pulumi in bash for instance
w

witty-candle-66007

11/24/2021, 6:52 PM
Not currently. But the Automation API which essentially encapsulates the Pulumi CLI in an SDK allows you to orchestrate things as such using Python/TypeScript/Go/.NET instead of bash. See: https://www.pulumi.com/docs/guides/automation-api/
b

bulky-policeman-29913

11/24/2021, 6:56 PM
ill have to dig into this thx @witty-candle-66007
p

prehistoric-nail-50687

11/24/2021, 7:53 PM
this might also be of interest: https://github.com/brandonkal/pulumi-command
b

bulky-policeman-29913

11/24/2021, 7:57 PM
I mean it would work but this stuff isnt part of my stack
for instance to send a python lambda as a zip up to aws, you need to bundle pip packages that are installed inside a docker container due to local machine platform differences (macos vs amazon linux).
I have a bash script that literally just spins up a docker container with a volume mount to spit out the python zip to send to the cloud with the pulumi typescript code.
It would be nice to make this part of the pulumi process without it being a resource that affects state..its a glorified make file if that makes sense
n

numerous-printer-41511

11/24/2021, 9:37 PM
why can’t you just write this in normal Python/Java/Go? sitting side-by-side with your pulumi code
invoked inside the pulumi.run function
a

alert-helmet-96588

12/01/2021, 6:27 PM
Since you have a bash script that does the job of packaging and sending to aws, I assume you can add another bash script that's going to invoke the first script and only if it's successful it will execute
pulumi up
?
b

bulky-policeman-29913

12/01/2021, 6:29 PM
Sure....I just wanted everything under the pulumi umbrella...one command deploy...might be wishful thinking
2 Views