Skip to content

distinguish among pods using same image in dev mode #851

@shaunc

Description

@shaunc

What happened?

I have two deployments running from the same image (with different commands): one is a web server, the other a utility image to allow command-line access. When I run devspace dev I get a stream of messages of the form:

[warn]   Multiple pods with image selector 'factfiber/crane-web-django:59c46897-shauncutts-kvTIqn' found. Using first pod found

I presume devspace is trying to match up running pods to deployments based on image. However, this is not unique in my case. I presume this is because of sync or auto reload issues. I guess for auto reload the should both be reloaded. For sync I only specify one deployment -- if the problem is sync, I guess no need to used the image name, but a selector based on (e.g) "app.kubernetes.io/component"?

What did you expect to happen instead?

No messages and sync/reload working as specified

How can we reproduce the bug? (as minimally and precisely as possible)

Create two deployments from one image and specify sync & autoreload

Local Environment:

  • Operating System: windows | linux | mac
  • Deployment method: helm | kubectl apply

Mac, helm

Kubernetes Cluster:

  • Cloud Provider: google | aws | azure | DevSpace Cloud | DevSpace Cloud Enterprise | other
  • Kubernetes Version: [use kubectl version]

local kubernetes via docker for Mac ;

Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.2", GitCommit:"c97fe5036ef3df2967d086711e6c0c405941e14b", GitTreeState:"clean", BuildDate:"2019-10-15T23:41:55Z", GoVersion:"go1.12.10", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"14", GitVersion:"v1.14.8", GitCommit:"211047e9a1922595eaa3a1127ed365e9299a6c23", GitTreeState:"clean", BuildDate:"2019-10-15T12:02:12Z", GoVersion:"go1.12.10", Compiler:"gc", Platform:"linux/amd64"}

Anything else we need to know?

/kind bug

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/port-forwardingIssues related to port forwardingarea/syncIssues related to the real-time code synchronizationneeds-informationIndicates an issue needs more information to work on it

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions