Update SGX SDK to 2.21 #81
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) 2022 MobileCoin Inc. | |
name: ci | |
on: | |
pull_request: | |
push: | |
tags: | |
- 'v*.*.*' | |
env: | |
BASE_DOCKER_REPO: mobilecoin/rust-sgx-base | |
BUILDER_DOCKER_REPO: mobilecoin/builder-install | |
PUSH: ${{ github.event_name == 'pull_request' && 'false' || 'true' }} | |
jobs: | |
docker: | |
runs-on: [self-hosted, Linux, small] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Docker meta for rust-sgx-base | |
id: base_meta | |
uses: docker/metadata-action@v3 | |
with: | |
flavor: latest=true | |
images: ${{ env.BASE_DOCKER_REPO }} | |
tags: | | |
type=ref,event=branch | |
type=semver,pattern=v{{version}} | |
type=semver,pattern=v{{major}}.{{minor}} | |
type=semver,pattern=v{{major}} | |
type=sha | |
- name: Docker meta for builder-install | |
id: builder_meta | |
uses: docker/metadata-action@v3 | |
with: | |
flavor: latest=true | |
images: ${{ env.BUILDER_DOCKER_REPO }} | |
tags: | | |
type=ref,event=branch | |
type=semver,pattern=v{{version}} | |
type=semver,pattern=v{{major}}.{{minor}} | |
type=semver,pattern=v{{major}} | |
type=sha | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to DockerHub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build and maybe push rust-sgx-base | |
uses: docker/build-push-action@v3 | |
with: | |
context: . | |
target: rust-sgx-base | |
cache-from: type=registry,ref=${{ env.BASE_DOCKER_REPO }}:buildcache | |
cache-to: type=registry,ref=${{ env.BASE_DOCKER_REPO }}:buildcache | |
labels: ${{ steps.base_meta.outputs.labels }} | |
tags: ${{ steps.base_meta.outputs.tags }} | |
push: ${{ env.PUSH }} | |
- name: Build and maybe push builder-install | |
uses: docker/build-push-action@v3 | |
with: | |
context: . | |
target: builder-install | |
cache-from: type=registry,ref=${{ env.BUILDER_DOCKER_REPO }}:buildcache | |
cache-to: type=registry,ref=${{ env.BUILDER_DOCKER_REPO }}:buildcache | |
labels: ${{ steps.builder_meta.outputs.labels }} | |
tags: ${{ steps.builder_meta.outputs.tags }} | |
push: ${{ env.PUSH }} | |
# via https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-only-cancel-in-progress-jobs-or-runs-for-the-current-workflow | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true |