This repository was archived by the owner on Apr 27, 2020. It is now read-only.

Description
Is this a BUG REPORT or FEATURE REQUEST?:
What happened:
The put step with a wait_until_ready_selector is returning success immediately. It's almost too fast for its own good!
What you expected to happen:
I expect the wait step to wait until the deployment update is complete.
How to reproduce it (as minimally and precisely as possible):
Have a kubernetes deployment with a normal RollingUpdate strategy. Use this kubernetes-resource to put changes to the deployment like so:
- put: prod-kube
params:
kubectl: apply -f ymls/my-app-deployment.yml
wait_until_ready: 60
wait_until_ready_selector: app=my-app
When this step runs I see this in the output:
+ kubectl apply -f ymls/my-app-deployment.yml
deployment.extensions/my-app configured
Waiting for pods to be ready for 60s (interval: 3s, selector: app=my-app)
Waiting for pods to be ready... (0/0)
This returns true immediately despite the fact that the new pod/replicaset hasn't actually spun up yet. It seems like resource is checking the ready status before the new pod is even created. Likely some kind of race condition with Kubernetes.
Environment:
- Concourse CI version: 5.7.0
- kubernetes-resource image version: 1.15