Skip to content

Commit

Permalink
Merge pull request #2132 from edcdavid/fix-kubeconfig-location
Browse files Browse the repository at this point in the history
OCPBUGS-46376: Disk encryption with TPM PCR 1 and 7 protection: upgrade not detected with TALM method
  • Loading branch information
openshift-merge-bot[bot] authored Dec 12, 2024
2 parents 6d74bf1 + 6f69763 commit 089d5f9
Show file tree
Hide file tree
Showing 8 changed files with 33 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,6 @@ ${MCMAKER} -stdout -name 01-disk-encryption-rebind -mcp "${MCPROLE}" \
file -source hwupgrade-detection-methods/fwup.sh -path /usr/local/bin/hwupgrade-detection-methods/fwup.sh -mode 0755 \
file -source hwupgrade-detection-methods/ostree.sh -path /usr/local/bin/hwupgrade-detection-methods/ostree.sh -mode 0755 \
file -source hwupgrade-detection-methods/talm.sh -path /usr/local/bin/hwupgrade-detection-methods/talm.sh -mode 0755 \
file -source order.conf -path /etc/systemd/system/crio-.scope.d/order.conf -mode 0644 \
unit -source pcr-rebind-boot.service \
unit -source pcr-disable-shutdown.service
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -o errexit -o nounset -o pipefail

SPOKE_KUBECONFIG_PATH=/var/lib/kubelet/kubeconfig
SPOKE_KUBECONFIG_PATH=/etc/kubernetes/static-pod-resources/kube-apiserver-certs/secrets/node-kubeconfigs/lb-int.kubeconfig
HUB_SECRET_NAMESPACE=open-cluster-management-agent
HUB_SECRET_NAME=hub-kubeconfig-secret

Expand Down Expand Up @@ -31,12 +31,13 @@ isZtpState() {
talmState="$1"
RESULT=$FALSE

clusterName=$(oc --kubeconfig "$SPOKE_KUBECONFIG_PATH" get klusterlet klusterlet -ojsonpath='{.spec.clusterName}')
case "$talmState" in
"running")
RESULT=$(KUBECONFIG=/tmp/kubeconfig-hub oc get managedcluster "$(hostname --short)" -ojson | jq '.metadata.labels["ztp-running"]!=null')
RESULT=$(KUBECONFIG=/tmp/kubeconfig-hub oc get managedcluster "$clusterName" -ojson | jq '.metadata.labels["ztp-running"]!=null')
;;
"done")
RESULT=$(KUBECONFIG=/tmp/kubeconfig-hub oc get managedcluster "$(hostname --short)" -ojson | jq '.metadata.labels["ztp-done"]!=null')
RESULT=$(KUBECONFIG=/tmp/kubeconfig-hub oc get managedcluster "$clusterName" -ojson | jq '.metadata.labels["ztp-done"]!=null')
;;
*)
# Code to execute when no patterns match
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# This unit ensures that containers stay up on shutdown until the pcr-disable-shutdown service is able to run
[Unit]
Before=pcr-disable-shutdown.service
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[Service]
Type=oneshot
RemainAfterExit=true
ExecStart=/usr/bin/true
ExecStop=/usr/local/bin/disablePcrOnRebootOrShutdown.sh

[Install]
WantedBy=multi-user.target
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,13 @@ spec:
mode: 493
path: /usr/local/bin/hwupgrade-detection-methods/ostree.sh
- contents:
source: data:text/plain;charset=utf-8;base64,IyEvYmluL2Jhc2gKc2V0IC1vIGVycmV4aXQgLW8gbm91bnNldCAtbyBwaXBlZmFpbAoKU1BPS0VfS1VCRUNPTkZJR19QQVRIPS92YXIvbGliL2t1YmVsZXQva3ViZWNvbmZpZwpIVUJfU0VDUkVUX05BTUVTUEFDRT1vcGVuLWNsdXN0ZXItbWFuYWdlbWVudC1hZ2VudApIVUJfU0VDUkVUX05BTUU9aHViLWt1YmVjb25maWctc2VjcmV0CgojIHJldHJpZXZlcyB0aGUga3ViZWNvbmZpZyBmb3IgdGhpcyBzcG9rZSdzIGNsdXN0ZXIKZ2V0SHViS3ViZWNvbmZpZygpIHsKCWxvY2FsIGt1YmVDb25maWdQYXRoIG5hbWVzcGFjZSBzZWNyZXROYW1lIEtVQkVDT05GSUdfREFUQSBUTFNfS0VZIFRMU19DUlQKCglrdWJlQ29uZmlnUGF0aD0iJDEiCgluYW1lc3BhY2U9IiQyIgoJc2VjcmV0TmFtZT0iJ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crio-.scope.d/order.conf
systemd:
units:
- contents: |
Expand All @@ -57,8 +61,8 @@ spec:
[Service]
Type=oneshot
RemainAfterExit=true
ExecStart=/usr/bin/true
ExecStop=/usr/local/bin/disablePcrOnRebootOrShutdown.sh
[Install]
WantedBy=multi-user.target
enabled: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,13 @@ spec:
mode: 493
path: /usr/local/bin/hwupgrade-detection-methods/ostree.sh
- contents:
source: data:text/plain;charset=utf-8;base64,IyEvYmluL2Jhc2gKc2V0IC1vIGVycmV4aXQgLW8gbm91bnNldCAtbyBwaXBlZmFpbAoKU1BPS0VfS1VCRUNPTkZJR19QQVRIPS92YXIvbGliL2t1YmVsZXQva3ViZWNvbmZpZwpIVUJfU0VDUkVUX05BTUVTUEFDRT1vcGVuLWNsdXN0ZXItbWFuYWdlbWVudC1hZ2VudApIVUJfU0VDUkVUX05BTUU9aHViLWt1YmVjb25maWctc2VjcmV0CgojIHJldHJpZXZlcyB0aGUga3ViZWNvbmZpZyBmb3IgdGhpcyBzcG9rZSdzIGNsdXN0ZXIKZ2V0SHViS3ViZWNvbmZpZygpIHsKCWxvY2FsIGt1YmVDb25maWdQYXRoIG5hbWVzcGFjZSBzZWNyZXROYW1lIEtVQkVDT05GSUdfREFUQSBUTFNfS0VZIFRMU19DUlQKCglrdWJlQ29uZmlnUGF0aD0iJDEiCgluYW1lc3BhY2U9IiQyIgoJc2VjcmV0TmFtZT0iJDMiCglLVUJFQ09ORklHX0RBVEE9JChvYyAtLWt1YmVjb25maWcgIiRrdWJlQ29uZmlnUGF0aCIgZ2V0IHNlY3JldCAtbiAiJG5hbWVzcGFjZSIgIiRzZWNyZXROYW1lIiAtbyBqc29uIHwganEgLmRhdGEua3ViZWNvbmZpZyB8IHNlZCAncy8iLy9nJyB8IGJhc2U2NCAtZCkKCWlmIFsgLXogIiRLVUJFQ09ORklHX0RBVEEiIF07IHRoZW4KCQlyZXR1cm4gIiRGQUxTRSIKCWZpC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1JFVF9OQU1FOyB0aGVuCgkJbG9nSW5mbyAiVEFMTSBub3QgYXZhaWxhYmxlIG9yIGh1YiBrdWJlY29uZmlnIGlzIG5vIHJlYWR5IHlldCBhdCAkU1BPS0VfS1VCRUNPTkZJR19QQVRIIHBhdGgsIGNhbm5vdCBnZXQgc3Bva2Ugc2VjcmV0ICRIVUJfU0VDUkVUX05BTUUgaW4gJEhVQl9TRUNSRVRfTkFNRVNQQUNFIG5hbWVzcGFjZSIKCQlyZXR1cm4gIiRGQUxTRSIKCWZpCglpc1p0cFN0YXRlICJydW5uaW5nIgoJcmV0dXJuICQ/Cn0KCiMgQWRkIGEgbmV3IGZ1bmN0aW9uIHRvIHRoZSBhcnJheSBvZiB1cGRhdGUgZGV0ZWN0aW9uIG1ldGhvZHMKc2VydmVyVXBkYXRlRGV0ZWN0aW9uTWV0aG9kcys9KCJpc1RBTE1VcGRhdGluZyIpCg==
mode: 493
path: /usr/local/bin/hwupgrade-detection-methods/talm.sh
- contents:
source: data:text/plain;charset=utf-8;base64,IyBUaGlzIHVuaXQgZW5zdXJlcyB0aGF0IGNvbnRhaW5lcnMgc3RheSB1cCBvbiBzaHV0ZG93biB1bnRpbCB0aGUgcGNyLWRpc2FibGUtc2h1dGRvd24gc2VydmljZSBpcyBhYmxlIHRvIHJ1biAKW1VuaXRdCkJlZm9yZT1wY3ItZGlzYWJsZS1zaHV0ZG93bi5zZXJ2aWNlCg==
mode: 420
path: /etc/systemd/system/crio-.scope.d/order.conf
systemd:
units:
- contents: |
Expand All @@ -57,8 +61,8 @@ spec:
[Service]
Type=oneshot
RemainAfterExit=true
ExecStart=/usr/bin/true
ExecStop=/usr/local/bin/disablePcrOnRebootOrShutdown.sh
[Install]
WantedBy=multi-user.target
enabled: true
Expand Down
Loading

0 comments on commit 089d5f9

Please sign in to comment.