Skip to content

Using resolver as data oracle solution #42

Using resolver as data oracle solution

Using resolver as data oracle solution #42

Workflow file for this run

name: e2e driver-did-polygonid
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
run_e2e:
env:
STATE_CONTRACT_ADDRESS_AMOY: "0x1a4cC30f2aA0377b0c3bc9848766D90cb4404124"
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- name: Build file with supported networks
run: |
echo -e "polygon:" > resolvers.settings.yaml
echo -e " amoy:" >> resolvers.settings.yaml
echo -e " contractAddress: ${{ env.STATE_CONTRACT_ADDRESS_AMOY }}" >> resolvers.settings.yaml
echo -e " networkURL: ${{ secrets.POLYGON_AMOY_NODE_URL }}" >> resolvers.settings.yaml
- name: Docker build driver container
uses: docker/build-push-action@v3
with:
context: .
file: Dockerfile
load: true
tags: polygonid-did-driver:develop
cache-from: type=gha
cache-to: type=gha
- name: polygonid-did-driver
run: docker run -p 8080:8080 -d --network host --name polygonid-did-driver polygonid-did-driver:develop
- name: logs
run: docker logs polygonid-did-driver
- name: Readiness probe for issuer service
run: >
curl --connect-timeout 5
--max-time 10
--retry 10
--retry-max-time 120
--retry-connrefused
'http://localhost:8080/status'
# TESTS
- name: Run Newman e2e
id: e2e
continue-on-error: true
run: |
npm install -g newman && \
newman run tests/e2e/http_nameservice.postman_collection.json \
-g ./tests/e2e/dev_env.json \
--global-var issuer_server=${{ secrets.ISSUER_URL }} \
--bail --verbose
- name: e2e tests finished
if: steps.e2e.outcome != 'success'
run: exit 1
# / TESTS