Skip to content

Commit

Permalink
Fix wrong service target port
Browse files Browse the repository at this point in the history
Fixes #1
Fixes #2

Signed-off-by: Nick Revin <n@nrvn.cc>
  • Loading branch information
nrvnrvn committed May 17, 2019
1 parent 22ebf43 commit efe4c2e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions deploy/Deployment.yaml → deploy/ZZ_Deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ spec:
serviceAccountName: redis-operator
containers:
- name: redis-operator
image: amaiz/redis-operator:0.0.1
image: amaiz/redis-operator:0.0.2
imagePullPolicy: Always
env:
- name: WATCH_NAMESPACE
- name: WATCH_NAMESPACE # left empty to watch all namespaces
- name: OPERATOR_NAME
value: redis-operator
- name: POD_NAME
Expand Down
2 changes: 1 addition & 1 deletion pkg/controller/redis/object_generator.go
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ func generateService(r *k8sv1alpha1.Redis, serviceType int) (string, *corev1.Ser
Name: redisName,
Protocol: corev1.ProtocolTCP,
Port: redisPort,
TargetPort: intstr.FromInt(exporterPort),
TargetPort: intstr.FromInt(redisPort),
}}
if !reflect.DeepEqual(r.Spec.Exporter, k8sv1alpha1.ContainerSpec{}) {
ports = append(ports, corev1.ServicePort{
Expand Down

0 comments on commit efe4c2e

Please sign in to comment.