Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added sidechain docker release #1456

Merged
merged 9 commits into from
Sep 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 11 additions & 6 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,10 @@ jobs:
mode: teeracle
sgx_mode: HW
additional_features: dcap
- flavor_id: sidechain
mode: teeracle
sgx_mode: HW
additional_features: dcap

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -465,15 +469,15 @@ jobs:
name: integritee-worker-teeracle-${{ github.ref_name }}.tar.gz
path: .

- name: Download Worker Image
uses: actions/download-artifact@v3
with:
name: integritee-worker-sidechain-${{ github.ref_name }}.tar.gz
path: .

#
# Temporary comment out until we decide what to release
#
# - name: Download Integritee Service
# uses: actions/download-artifact@v3
# with:
# name: integritee-worker-sidechain-${{ github.sha }}
# path: integritee-worker-tmp

# - name: Download Integritee Client
# uses: actions/download-artifact@v3
# with:
Expand Down Expand Up @@ -515,6 +519,7 @@ jobs:
name: Docker ${{ github.ref_name }}
files: |
integritee-worker-teeracle-${{ github.ref_name }}.tar.gz
integritee-worker-sidechain-${{ github.ref_name }}.tar.gz
integritee-client
integritee-demo-validateer
enclave.signed.so
43 changes: 43 additions & 0 deletions .github/workflows/publish-docker-sidechain.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Publish Docker image for new sidechain release

on:
release:
types:
- published

jobs:
main:
name: Push Integritee Sidechain to Dockerhub
runs-on: [ self-hosted ]
steps:
- uses: actions/checkout@v3

- name: Download sidechain from release
uses: dsaltares/fetch-gh-release-asset@master
with:
version: "tags/${{ github.event.release.tag_name }}"
file: integritee-worker-sidechain-${{ github.event.release.tag_name }}.tar.gz
target: "integritee-worker-sidechain.tar.gz"
token: ${{ secrets.GITHUB_TOKEN }}


- name: Login to Dockerhub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}

- name: Load Worker & Push
env:
DOCKER_BUILDKIT: 1
run: |
docker image load --input integritee-worker-sidechain.tar.gz
docker images --all
docker push integritee/sidechain:${{ github.event.release.tag_name }}

- name: Delete images
run: |
if [[ "$(docker images -q integritee/sidechain:${{ github.event.release.tag_name }} 2> /dev/null)" != "" ]]; then
docker image rmi --force integritee/sidechain:${{ github.event.release.tag_name }} 2>/dev/null
fi
docker images --all