Add enclave ra tls demo into demo CI

This commit is contained in:
zongmin.gu 2021-04-15 14:10:38 +08:00 committed by Zongmin.Gu
parent 0c0c4c4abc
commit baf550d600
2 changed files with 30 additions and 1 deletions

@ -450,3 +450,32 @@ jobs:
sleep ${{ env.nap_time }};
docker exec flink_test bash -c "cd /root/occlum/demos/flink && SGX_MODE=SIM ./run_flink_on_occlum_glibc.sh task"
enclave_ra_tls_test:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
with:
submodules: true
- name: Get occlum version
run: echo "OCCLUM_VERSION=$(grep "Version =" src/pal/include/occlum_version.h | awk '{print $4}')" >> $GITHUB_ENV
- name: Create container
run: docker run -itd --name=enclave_ra_tls_test -v $GITHUB_WORKSPACE:/root/occlum occlum/occlum:${{ env.OCCLUM_VERSION }}-ubuntu18.04
- name: Build dependencies
run: docker exec enclave_ra_tls_test bash -c "cd /root/occlum; make submodule"
- name: Make install
run: docker exec enclave_ra_tls_test bash -c "cd /root/occlum; OCCLUM_RELEASE_BUILD=y make install"
- name: Download and build Enclave TLS
run: docker exec enclave_ra_tls_test bash -c "cd /root/occlum/demos/enclave_tls && ./download_and_build_enclave_tls.sh"
- name: Run the encalve tls server on Occlum
run: docker exec enclave_ra_tls_test bash -c "cd /root/occlum/demos/enclave_tls && SGX_MODE=SIM ./run_enclave_tls_server_in_occlum.sh"
- name: Run the encalve tls client
run: |
sleep ${{ env.nap_time }};
docker exec enclave_ra_tls_test bash -c "/opt/enclave-tls/bin/enclave-tls-client"

@ -17,4 +17,4 @@ cp /usr/lib/x86_64-linux-gnu/libsgx_dcap_quoteverify.so.1 image/opt/occlum/glibc
occlum build
# 3. Run enclave_tls_server
occlum run /bin/enclave-tls-server
occlum run /bin/enclave-tls-server &