refactor: skip sgx driver installation if already exists in OS #3062
refactor: skip sgx driver installation if already exists in OS #3062
Conversation
Thanks @Francis-Liu! We are currently only testing SGX up to Kubernetes v1.16. Is that correct? Do SGX drivers + workloads still not work in Kubernetes v1.17+ ? |
I ran our E2E tests against this change and SGX workloads were failing, indicating that we still need to do the drivers installation. |
Thank you @jackfrancis. Did you run the E2E testing using OpenEnclave Samples Tests? Regarding your first question, when testing aks-engine change, I did not explicitly specify which Kubernetes version to use. Could you elaborate your considerations on what might cause SGX driver and workload to be unable to run on Kubernetes v1.17+? From our side, we want the driver and workloads to be tested against latest Kubernetes version. |
We are running this spec to test: https://github.com/Azure/aks-engine/blob/master/test/e2e/kubernetes/workloads/sgx-test.yaml I'm not aware of any reason why things wouldn't work on >= 1.17, but our test cluster configuration only tests 1.16 and below: https://github.com/Azure/aks-engine/blob/master/test/e2e/test_cluster_configs/sgx.json Maybe there's no good reason for that. |
The information you provided is absolutely important! Regardless of whether we install the driver on the fly or not, the SGX driver was updated by Intel in such a way that For the |
From the pod:
|
The pod spec:
|
Thanks @jackfrancis. |
Signed-off-by: Francis Liu <Francis.Liu2012@gmail.com>
c065e2f
to
dfa00d1
Compare
Hi @jackfrancis, I have updated this PR: (1) fixed a bug in cse_main.sh, |
/azp run pr-e2e |
Azure Pipelines successfully started running 1 pipeline(s). |
Codecov Report
@@ Coverage Diff @@
## master #3062 +/- ##
==========================================
- Coverage 70.63% 70.58% -0.05%
==========================================
Files 145 145
Lines 25151 25219 +68
==========================================
+ Hits 17765 17802 +37
- Misses 6283 6312 +29
- Partials 1103 1105 +2
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
…#3062) Signed-off-by: Francis Liu <Francis.Liu2012@gmail.com>
Reason for Change:
Azure Ubuntu images is now shipped with Intel SGX driver by default. We skip the driver installation if "/dev/sgx" is detected. We keep the installation code in case of a custom image is used.
Issue Fixed:
NA
Requirements:
Notes:
None