Fix default namespace installation error for tigera and custom-resource#498
Merged
ArangoGutierrez merged 1 commit intomainfrom Sep 8, 2025
Merged
Fix default namespace installation error for tigera and custom-resource#498ArangoGutierrez merged 1 commit intomainfrom
ArangoGutierrez merged 1 commit intomainfrom
Conversation
Pull Request Test Coverage Report for Build 17512924608Details
💛 - Coveralls |
Signed-off-by: Shiva Kumar (SW-CLOUD) <shivaku@nvidia.com>
3f83be8 to
74ecf48
Compare
Collaborator
|
/ok to test 74ecf48 |
ArangoGutierrez
approved these changes
Sep 8, 2025
tariq1890
reviewed
Sep 8, 2025
| # based on https://docs.tigera.io/calico/latest/getting-started/kubernetes/quickstart | ||
| echo "Installing Calico ${CALICO_VERSION}..." | ||
| with_retry 3 10s kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/tigera-operator.yaml | ||
| with_retry 3 10s kubectl get installation default -n tigera-operator || kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/tigera-operator.yaml |
Contributor
There was a problem hiding this comment.
- The kubectl calls should be consistent. Here you have one kubectl call using the
--kubeconfigand the other without the flag - Moreover, the
kubectl get installationcall seems unnecessary here. The creation of the installation custom resource does not happen until L138, so this change should be reverted. It is unncessary here
tariq1890
reviewed
Sep 8, 2025
| # Install Calico custom resources | ||
| echo "Installing Calico custom resources..." | ||
| with_retry 3 10s kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/custom-resources.yaml | ||
| with_retry 3 10s kubectl get installation default -n tigera-operator || kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/custom-resources.yaml |
Contributor
There was a problem hiding this comment.
-
The kubectl calls should be consistent. Here you have one kubectl call using the --kubeconfig and the other without the flag
-
Also, it is always better to use the FQDN of a custom resource when referencing it in automation scripts
Suggested change
| with_retry 3 10s kubectl get installation default -n tigera-operator || kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/custom-resources.yaml | |
| with_retry 3 10s kubectl get installations.operator.tigera.io default -n tigera-operator || kubectl --kubeconfig $KUBECONFIG create -f https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/custom-resources.yaml |
Contributor
Author
There was a problem hiding this comment.
opened new PR and testing @tariq1890 @ArangoGutierrez
#499
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.