-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1720 from skynet2/extra-publish
feat: extra publish
- Loading branch information
Showing
1 changed file
with
219 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,219 @@ | ||
# | ||
# Copyright SecureKey Technologies Inc. All Rights Reserved. | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
name: mocks | ||
on: | ||
push: | ||
branches: | ||
- main | ||
jobs: | ||
mock-webhook: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 45 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Set ENV vars | ||
run: | | ||
TAG=$(git describe --tags --always `git rev-list --tags --max-count=1`) | ||
echo "IMAGE_TAG"=$TAG >> $GITHUB_ENV | ||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ secrets.CR_USER }} | ||
password: ${{ secrets.CR_PAT }} | ||
|
||
- name: Setup Go 1.21 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: '1.21' | ||
|
||
- run: make sample-webhook | ||
|
||
- name: Build and Push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
file: ./images/mocks/webhook/Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
GO_IMAGE=golang | ||
ALPINE_VER=3.18 | ||
GO_VER=1.21 | ||
ALPINE_IMAGE=alpine | ||
push: false | ||
tags: | | ||
ghcr.io/trustbloc/mock-webhook:latest | ||
ghcr.io/trustbloc/mock-webhook:${{ env.IMAGE_TAG }}-latest | ||
mock-login-consent: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 45 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Set ENV vars | ||
run: | | ||
TAG=$(git describe --tags --always `git rev-list --tags --max-count=1`) | ||
echo "IMAGE_TAG"=$TAG >> $GITHUB_ENV | ||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ secrets.CR_USER }} | ||
password: ${{ secrets.CR_PAT }} | ||
|
||
- name: Build and Push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: test/bdd/loginconsent | ||
file: ./images/mocks/loginconsent/Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
GO_IMAGE=golang | ||
ALPINE_VER=3.18 | ||
GO_VER=1.21 | ||
ALPINE_IMAGE=alpine | ||
push: false | ||
tags: | | ||
ghcr.io/trustbloc/mock-login-consent:latest | ||
ghcr.io/trustbloc/mock-login-consent:${{ env.IMAGE_TAG }}-latest | ||
mock-trustregistry: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 45 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Set ENV vars | ||
run: | | ||
TAG=$(git describe --tags --always `git rev-list --tags --max-count=1`) | ||
echo "IMAGE_TAG"=$TAG >> $GITHUB_ENV | ||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ secrets.CR_USER }} | ||
password: ${{ secrets.CR_PAT }} | ||
|
||
- name: Build and Push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: test/bdd/trustregistry | ||
file: ./images/mocks/trustregistry/Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
GO_IMAGE=golang | ||
ALPINE_VER=3.18 | ||
GO_VER=1.21 | ||
ALPINE_IMAGE=alpine | ||
push: false | ||
tags: | | ||
ghcr.io/trustbloc/mock-trustregistry:latest | ||
ghcr.io/trustbloc/mock-trustregistry:${{ env.IMAGE_TAG }}-latest | ||
mock-attestation: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 45 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Set ENV vars | ||
run: | | ||
TAG=$(git describe --tags --always `git rev-list --tags --max-count=1`) | ||
echo "IMAGE_TAG"=$TAG >> $GITHUB_ENV | ||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ secrets.CR_USER }} | ||
password: ${{ secrets.CR_PAT }} | ||
|
||
- name: Build and Push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: test/bdd/attestation | ||
file: ./images/mocks/attestation/Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
GO_IMAGE=golang | ||
ALPINE_VER=3.18 | ||
GO_VER=1.21 | ||
ALPINE_IMAGE=alpine | ||
push: false | ||
tags: | | ||
ghcr.io/trustbloc/mock-attestation:latest | ||
ghcr.io/trustbloc/mock-attestation:${{ env.IMAGE_TAG }}-latest | ||
mock-cognito-auth: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 45 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Set ENV vars | ||
run: | | ||
TAG=$(git describe --tags --always `git rev-list --tags --max-count=1`) | ||
echo "IMAGE_TAG"=$TAG >> $GITHUB_ENV | ||
- name: Setup Go 1.21 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: '1.21' | ||
|
||
- run: make sample-cognito-auth | ||
|
||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ secrets.CR_USER }} | ||
password: ${{ secrets.CR_PAT }} | ||
|
||
- name: Build and Push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
file: ./images/mocks/cognito-auth/Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
GO_IMAGE=golang | ||
ALPINE_VER=3.18 | ||
GO_VER=1.21 | ||
ALPINE_IMAGE=alpine | ||
push: false | ||
tags: | | ||
ghcr.io/trustbloc/mock-cognito-auth:latest | ||
ghcr.io/trustbloc/mock-cognito-auth:${{ env.IMAGE_TAG }}-latest |