File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
ci-operator/step-registry/ipi/deprovision/artifacts/artifacts Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,8 @@ echo "Gathering artifacts ..."
22
22
mkdir -p ${ARTIFACT_DIR} /pods ${ARTIFACT_DIR} /nodes ${ARTIFACT_DIR} /metrics ${ARTIFACT_DIR} /bootstrap ${ARTIFACT_DIR} /network
23
23
24
24
oc --insecure-skip-tls-verify --request-timeout=5s get nodes -o jsonpath --template ' {range .items[*]}{.metadata.name}{"\n"}{end}' > /tmp/nodes
25
+ oc --insecure-skip-tls-verify --request-timeout=5s get nodes -o jsonpath --template ' {range .items[*]}{.spec.providerID}{"\n"}{end}' | sed ' s|.*/||' > /tmp/node-provider-IDs
26
+ oc --insecure-skip-tls-verify --request-timeout=5s -n openshift-machine-api get machines -o jsonpath --template ' {range .items[*]}{.spec.providerID}{"\n"}{end}' | sed ' s|.*/||' >> /tmp/node-provider-IDs
25
27
oc --insecure-skip-tls-verify --request-timeout=5s get pods --all-namespaces --template ' {{ range .items }}{{ $name := .metadata.name }}{{ $ns := .metadata.namespace }}{{ range .spec.containers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ range .spec.initContainers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ end }}' > /tmp/containers
26
28
oc --insecure-skip-tls-verify --request-timeout=5s get pods -l openshift.io/component=api --all-namespaces --template ' {{ range .items }}-n {{ .metadata.namespace }} {{ .metadata.name }}{{ "\n" }}{{ end }}' > /tmp/pods-api
27
29
@@ -85,3 +87,4 @@ done < /tmp/containers
85
87
86
88
echo " Snapshotting prometheus (may take 15s) ..."
87
89
queue ${ARTIFACT_DIR} /metrics/prometheus.tar.gz oc --insecure-skip-tls-verify exec -n openshift-monitoring prometheus-k8s-0 -- tar cvzf - -C /prometheus .
90
+ FILTER=gzip queue ${ARTIFACT_DIR} /metrics/prometheus-target-metadata.json.gz oc --insecure-skip-tls-verify exec -n openshift-monitoring prometheus-k8s-0 -- /bin/bash -c " curl -G http://localhost:9090/api/v1/targets/metadata --data-urlencode 'match_target={instance!=\"\" }'"
You can’t perform that action at this time.
0 commit comments