https://pulumi.com logo
#kubernetes
Title
# kubernetes
r

rhythmic-napkin-82334

08/25/2020, 8:19 AM
Hey all, I have problems using
pulumi_kubernetes
on my mac when trying to `import pulumi_kubernetes`:
Copy code
ModuleNotFoundError: No module named 'pulumi_kubernetes'
I installed pulumi with
brew install pulumi
and additionally use a conda environment. further information: • pulumi v2.9.0 • see
conda list
output in image attached PS:
pulumi up
with another script where I use only
pulumi
and
pulumi_aws
works fine!
l

limited-rainbow-51650

08/25/2020, 9:41 AM
I have never used Python with Pulumi before, but when I look at the provided example, I nowhere see
import pulumi_kubernetes
in the code. I always see
from pulumi_kubernetes.<subpackage> import <class>
https://github.com/pulumi/examples/tree/master/kubernetes-py-guestbook
r

rhythmic-napkin-82334

08/25/2020, 10:56 AM
Thanks for your help, but I have seen
import pulumi_kubernetes
working before. However, I am a little bit confused on what exactly happens, when I call
pulumi up
. 1. The pulumi that was installed with brew executes the command and has access to python packages that are in the mac os standard python installation. 2. The pulumi that was installed with brew executes the command and has access to python packages that are in the mac os standard python installation and the packages that are in the activated conda environment. 3. The pulumi from the conda environment is called with all python packages available in the conda environment. Subsequently, the following questions arise: • If pulumi is entirely run from packages in virtual environment (conda, venv, …) why
brew install pulumi
at all? • If pulumi is entirely run from packages in base environment, why use virtual environments? Reconsidering the questions origin, it’s probably more appropriate in the #python channel
6 Views