Trying to build a full demo of a containerised app...
# python
Trying to build a full demo of a containerised app. Does the python library not support building docker images yet? Seems like it can only work with existing images at the moment, but not build new ones.
does not exist for Python yet
oh, nvm, i see it in PyPI and github, but not pulumi's website
imho, don't do that anyway? Pulumi isn't meant to be a general-purpose build tool? idk, I'm doing a similar thing with lambda packages, so 🤷
now you got me wondering about that
because in my ideal world, I would have a bunch of stuff built by various pipelines and then pulled in and tied together by pulumi, but wooph that sounds like a mountain of work
also, my lambda stuff integrates with pulumi (passes resources into it, and some codegen), so what i just described is only sorta possible
Yeah, which is why I was wondering if I could use pulumi. It's in the TS library, but not in python yet it seems. @white-balloon-205 any idea when this might change?
We are considering re-writing the
component to be a native component so that it can more easily fit into deployment lifecycle (a few of the issues in that repro are blocked on doing this before we can address them properly). Doing so would also make this available in Python. But this library is also just some convenience wrappers - you can do the same yourself if you want for targeted use cases - or port some/all of the existing library there to Python. So definitely these same scenarios are possible in Python as well - and we hope to have the exact same libraries also available in the future.
Cool, this is for a conference demo, I assume I can just call the docker binary from python to build and push the image inline with the rest of the code.
This wouldn't be a managed pulumi resource then, right?
it is done inside a resource, but you don’t really have to. You could just have a function which invokes
docker build
and conditionally
docker push
only when not in preview.
👍 thanks Luke. What I expected.