mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-25 20:53:33 +00:00
Merge pull request #25492 from metral/test-cmd
fix filepath for cert_data in hack/test-cmd.sh
This commit is contained in:
commit
ba170aa191
@ -305,7 +305,7 @@ runTests() {
|
|||||||
kubectl config set-cluster test-cluster --server="https://does-not-work"
|
kubectl config set-cluster test-cluster --server="https://does-not-work"
|
||||||
|
|
||||||
# Get the api cert and add a comment to avoid flag parsing problems
|
# Get the api cert and add a comment to avoid flag parsing problems
|
||||||
cert_data=$(echo "#Comment" && cat "${TMPDIR:-/tmp/}apiserver.crt")
|
cert_data=$(echo "#Comment" && cat "${TMPDIR:-/tmp}/apiserver.crt")
|
||||||
|
|
||||||
kubectl config set clusters.test-cluster.certificate-authority-data "$cert_data" --set-raw-bytes
|
kubectl config set clusters.test-cluster.certificate-authority-data "$cert_data" --set-raw-bytes
|
||||||
r_writen=$(kubectl config view --raw -o jsonpath='{.clusters[?(@.name == "test-cluster")].cluster.certificate-authority-data}')
|
r_writen=$(kubectl config view --raw -o jsonpath='{.clusters[?(@.name == "test-cluster")].cluster.certificate-authority-data}')
|
||||||
|
Loading…
Reference in New Issue
Block a user