diff --git a/.github/workflows/manually_build_for_testing.yml b/.github/workflows/manually_build_for_testing.yml index 9637cbd3..8a0ced19 100644 --- a/.github/workflows/manually_build_for_testing.yml +++ b/.github/workflows/manually_build_for_testing.yml @@ -26,6 +26,8 @@ on: - bigdl-ppml-trusted-realtime-ml-scala-occlum - bigdl-ppml-kmsutil - bigdl-ppml-pccs + - bigdl-ppml-trusted-python-toolkit-base + - bigdl-ppml-trusted-python-toolkit-ref tag: description: 'docker image tag (e.g. test)' required: true @@ -572,3 +574,65 @@ jobs: docker tag ${IMAGE}:${TAG} 10.239.45.10/arda/${IMAGE}:${TAG} docker push 10.239.45.10/arda/${IMAGE}:${TAG} docker rmi -f ${IMAGE}:${TAG} 10.239.45.10/arda/${IMAGE}:${TAG} + +bigdl-ppml-trusted-python-toolkit-base: + if: ${{ github.event.inputs.artifact == 'bigdl-ppml-trusted-python-toolkit-base' || github.event.inputs.artifact == 'all' }} + runs-on: [self-hosted, Shire] + steps: + - uses: actions/checkout@v3 + with: + ref: ${{ github.event.inputs.sha }} + - name: docker login + run: | + docker login -u ${DOCKERHUB_USERNAME} -p ${DOCKERHUB_PASSWORD} + - name: bigdl-ppml-trusted-python-toolkit-base + run: | + echo "##############################################################" + echo "########## bigdl-ppml-trusted-python-toolkit-base ############" + echo "##############################################################" + export base_image=intelanalytics/bigdl-ppml-gramine-base + export image=intelanalytics/bigdl-ppml-trusted-python-toolkit-base + cd ppml/trusted-python-toolkit + sudo docker build \ + --no-cache=true \ + --build-arg http_proxy=${HTTP_PROXY} \ + --build-arg https_proxy=${HTTPS_PROXY} \ + --build-arg BASE_IMAGE_NAME=${base_image} \ + --build-arg BASE_IMAGE_TAG=${TAG} \ + -t ${image}:${TAG} -f ./Dockerfile . + sudo docker push ${image}:${TAG} + sudo docker tag ${image}:${TAG} 10.239.45.10/arda/${image}:${TAG} + sudo docker push 10.239.45.10/arda/${image}:${TAG} + sudo docker rmi -f ${image}:${TAG} + + bigdl-ppml-trusted-python-toolkit-ref: + if: ${{ github.event.inputs.artifact == 'bigdl-ppml-trusted-python-toolkit-ref' || github.event.inputs.artifact == 'all' }} + runs-on: [self-hosted, Shire] + steps: + - uses: actions/checkout@v3 + with: + ref: ${{ github.event.inputs.sha }} + - name: docker login + run: | + docker login -u ${DOCKERHUB_USERNAME} -p ${DOCKERHUB_PASSWORD} + - name: bigdl-ppml-trusted-python-toolkit-ref + run: | + echo "##############################################################" + echo "########## bigdl-ppml-trusted-python-toolkit-ref #############" + echo "##############################################################" + export base_image=intelanalytics/bigdl-ppml-trusted-python-toolkit-base + export image=intelanalytics/bigdl-ppml-trusted-python-toolkit-ref + cd ppml/trusted-python-toolkit + openssl genrsa -3 -out enclave-key.pem 3072 + sudo docker build \ + --no-cache=true \ + --build-arg http_proxy=${HTTP_PROXY} \ + --build-arg https_proxy=${HTTPS_PROXY} \ + --build-arg BASE_IMAGE_NAME=${base_image} \ + --build-arg SGX_MEM_SIZE=64G \ + --build-arg BASE_IMAGE_TAG=${TAG} \ + -t ${image}:${TAG} -f ./Dockerfile . + sudo docker push ${image}:${TAG} + sudo docker tag ${image}:${TAG} 10.239.45.10/arda/${image}:${TAG} + sudo docker push 10.239.45.10/arda/${image}:${TAG} + sudo docker rmi -f ${image}:${TAG}