Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redis operator is not able to differentiate between multiple clusters when run on different ports other than 6379 which is hardcoded. #57

Open
irshadawake opened this issue Dec 4, 2019 · 1 comment

Comments

@irshadawake
Copy link

irshadawake commented Dec 4, 2019

Redis operator is not able to differentiate between multiple clusters when run on different ports other than 6379 which is hardcoded.

Steps to reproduce:

  1. deploy redis cluster with hostnetwork=true on port 6379.
    ( operator creates a cluster with all pods running on 6379 and all good)
  2. deploy 2nd cluster with hostnetwork=true on port 6389.
    (operator creates svc for the second cluster with port no:6379 as it is hardcoded here:
    Ports: []kapiv1.ServicePort{{Port: 6379, Name: "redis"}},
    )
  3. the operator now gets confused and mixes both the clusters together.
    RedisCluster.txt
@irshadawake irshadawake changed the title Redis operator is not respecting clusters when run on different port other than 6379 which is hardcoded Redis operator is not able to differentiate between multiple clusters when run on different ports other than 6379 which is hardcoded. Dec 9, 2019
@irshadawake
Copy link
Author

Scenario: Redis operator creates a service per cluster. However, when we try to create multiple clusters with different ports, as the redis port is hardcoded in the operator code, it creates a wrong service and messes up the clusters.
Workaround: Over-ridden the service creation just before the cluster is created manually. Hence the operator fails to create the wrong service and endpoints, but works as expected with all the features. This step can be skipped in future if the community gets a fix for the same.

Please let me know if this can have unexpected side effects too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant