Merge pull request #283 from achaikou/assure_4_samples #126
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
name: E2E tests | |
on: | |
push: | |
branches: [master, e2e_tests] | |
workflow_dispatch: | |
jobs: | |
# The following secrets are required: | |
# STORAGE_ACCOUNT_NAME : name of the storage account with uploaded testdata (without blob.core.windows.net) | |
# STORAGE_ACCOUNT_KEY : key used to access storage | |
e2e_tests: | |
name: Run e2e tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Load openvds image | |
uses: "./.github/actions/load_openvds_image" | |
- name: Build and Run server | |
env: | |
VDSSLICE_STORAGE_ACCOUNTS: https://${{ secrets.STORAGE_ACCOUNT_NAME }}.blob.core.windows.net | |
# Keep cache size big enough so that cache is never full | |
# thus tests can rely on the key to be accepted on the first try | |
VDSSLICE_CACHE_SIZE: 50 | |
run: | | |
tag=server | |
DOCKER_BUILDKIT=1 docker build \ | |
-f Dockerfile \ | |
--build-arg OPENVDS_IMAGE=${{ env.OPENVDS_IMAGE_TAG }} \ | |
--target runner \ | |
--tag $tag \ | |
. | |
docker run \ | |
-e VDSSLICE_STORAGE_ACCOUNTS \ | |
-e VDSSLICE_CACHE_SIZE \ | |
-d \ | |
-p 8080:8080 \ | |
$tag | |
- name: Run E2E tests | |
env: | |
ENDPOINT: http://localhost:8080 | |
STORAGE_ACCOUNT_NAME: ${{ secrets.STORAGE_ACCOUNT_NAME }} | |
STORAGE_ACCOUNT_KEY: ${{ secrets.STORAGE_ACCOUNT_KEY }} | |
run: | | |
tag=e2e_tests | |
docker build -f tests/e2e/Dockerfile -t $tag . | |
docker run \ | |
-e ENDPOINT \ | |
-e STORAGE_ACCOUNT_NAME \ | |
-e STORAGE_ACCOUNT_KEY \ | |
--network="host" \ | |
$tag |