-
Bug
-
Resolution: Not a Bug
-
Undefined
-
None
-
4.14, 4.15, 4.16, 4.17
-
None
-
Quality / Stability / Reliability
-
False
-
-
None
-
Low
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Description of problem:
After creating a hosted cluster and after the hostedcluster Available condition met, changing the kube-apiserver servicePublishingStrategy.nodePort.port field doesn't reconcile the service.
Version-Release number of selected component (if applicable):
4.16 mgmt cluster + mce stable 2.6 - on BM
How reproducible:
Always
Steps to Reproduce:
1. create an hosted cluster with hcp create cluster agent ...
/tmp/${HYPERSHIFT_NAME} create cluster agent ${EXTRA_ARGS} \
--name=${CLUSTER_NAME} \
--pull-secret=/tmp/.dockerconfigjson \
--agent-namespace="${AGENT_NAMESPACE}" \
--namespace local-cluster \
--base-domain=${BASEDOMAIN} \
--api-server-address=api.${CLUSTER_NAME}.${BASEDOMAIN} \
--image-content-sources "${SHARED_DIR}/mgmt_icsp.yaml" \
--ssh-key="${SHARED_DIR}/id_rsa.pub" \
--release-image ${RELEASE_IMAGE}
2. create the ManagedCluster object
apiVersion: cluster.open-cluster-management.io/v1
kind: ManagedCluster
metadata:
annotations:
import.open-cluster-management.io/hosting-cluster-name: local-cluster
import.open-cluster-management.io/klusterlet-deploy-mode: Hosted
open-cluster-management/created-via: other
labels:
cloud: auto-detect
cluster.open-cluster-management.io/clusterset: default
name: ${CLUSTER_NAME}
vendor: OpenShift
name: ${CLUSTER_NAME}
spec:
hubAcceptsClient: true
leaseDurationSeconds: 60
EOF
3. Wait for the cluster to be avilable:
echo "Waiting for cluster to become available"
oc wait --timeout=30m --for=condition=Available --namespace=local-cluster hostedcluster/${CLUSTER_NAME}
4. Patch the hostedcluster object
oc patch -n local-cluster "hostedcluster/${CLUSTER_NAME}" --type=merge \
--patch='{"spec":{"services":
[{"service":"APIServer","servicePublishingStrategy":{"nodePort":{"address":"'"${address}"'","port":30643},"type":"NodePort"}},
{"service":"OAuthServer","servicePublishingStrategy":{"type":"Route"}},
{"service":"OIDC","servicePublishingStrategy":{"type":"None"}},
{"service":"Konnectivity","servicePublishingStrategy":{"type":"Route"}},
{"service":"Ignition","servicePublishingStrategy":{"type":"Route"}},
{"service":"OVNSbDb","servicePublishingStrategy":{"type":"Route"}}
]}}'
Actual results:
5. The kube-apiserver nodePort service is not reconciled
Expected results:
5. The kube-apiserver nodePort service should get the nodePort change
Additional info:
manually deleting the service will create the service again, with the correct port.
- relates to
-
HOSTEDCP-1669 Enforce CEL immutability day 1 and day 2 validation for ServicePublishingStrategy
-
- Closed
-