Deploy the Changes

Now let’s deploy our changes.

$ pulumi up

Pulumi computes the minimally disruptive change to achieve the desired state described by the program.

Previewing update (dev):

     Type                        Name            Plan
     pulumi:pulumi:Stack         quickstart-dev
 +   └─ kubernetes:core:Service  nginx           create

    + 1 to create
    2 unchanged

Do you want to perform this update?
> no

Pulumi will create the service since it is now defined in the program.

Do you want to perform this update? yes
Updating (dev):

     Type                        Name            Status
     pulumi:pulumi:Stack         quickstart-dev
 +   └─ kubernetes:core:Service  nginx           created

  + ip  : ""
  - name: "nginx-98nrfhk6"

    + 1 created
    2 unchanged

Duration: 12s

You can see we now have an ip stack output that we can curl to get the output from the service.

Note: minikube does not support type LoadBalancer; if you are deploying to minikube, make sure to run kubectl port-forward svc/frontend 8080:80 to forward the cluster port to the local machine and access the service via localhost:8080.

$ curl $(pulumi stack output ip)
<!DOCTYPE html>
<title>Welcome to nginx!</title>
    body {
        width: 35em;
        margin: 0 auto;
        font-family: Tahoma, Verdana, Arial, sans-serif;
<h1>Welcome to nginx!</h1>
<p>If you see this page, the nginx web server is successfully installed and
working. Further configuration is required.</p>

<p>For online documentation and support please refer to
<a href=""></a>.<br/>
Commercial support is available at
<a href=""></a>.</p>

<p><em>Thank you for using nginx.</em></p>

Next, we’ll destroy the stack.