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

busy-umbrella-36067

10/18/2018, 4:22 PM
seeing this issue come up pulumi keeps attempting to recreate a service that can’t init (wrong labels in the selector). after fixing the label selector and preparing to update,
pulumi refresh
fails to complete:
Copy code
Diagnostics:
  kubernetes:core:Service: XXXXXXXXX
    error: Preview failed: 2 errors occurred:

    * Resource 'XXXXXXXXX' was created but failed to initialize
    * Service does not target any Pods. Application Pods may failed to become alive, or field '.spec.selector' may not match labels on any Pods

error: an error occurred while advancing the preview
the failed resource is never added to state, and the new resource with the fixed label can’t be created because there is a name collision with the “tainted” resource
c

creamy-potato-29402

10/18/2018, 4:31 PM
Hmm... It seems to me the refresh should fail?
If the resource is in a bad state the refresh should not succeed. The update should work by itself though
b

busy-umbrella-36067

10/18/2018, 4:33 PM
the problem is that the updates attempt to create the service
the preview shows
create
for all of the previously failed services, and results in
** creating failed**
c

creamy-potato-29402

10/18/2018, 4:34 PM
Hmm.
That doesn't sound right I'll take a look when I get in
3 Views