Skip to content

Fix zen project imports #179

Fix zen project imports

Fix zen project imports #179

name: github-actions
on: [push]
env:
BUILD_IMAGE: bedasoftware/fhir-sdc
CACHE_IMAGE: bedasoftware/fhir-sdc:latest
TESTS_AIDBOX_LICENSE: ${{ secrets.TESTS_AIDBOX_LICENSE }}
jobs:
Build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: docker pull ${{ env.CACHE_IMAGE }} || true
- run: >-
docker build --cache-from ${{ env.CACHE_IMAGE }}
--tag ${{ env.BUILD_IMAGE }} .
- name: Run tests
run: >-
mkdir ./tests_zen_project/zen-packages/ &&
ls -la ./tests_zen_project &&
id &&
chmod -R 0777 ./tests_zen_project &&
./run_test.sh
- name: Show logs
if: ${{ failure() }}
run: docker-compose -f docker-compose.tests.yaml logs
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: Extract branch name
shell: bash
run: echo "branch=$(echo ${GITHUB_REF#refs/heads/})" >>$GITHUB_OUTPUT
id: extract_branch
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- run: docker run --rm --privileged tonistiigi/binfmt --install all
- run: >-
docker buildx build --platform linux/arm64,linux/amd64
--cache-from ${{ env.CACHE_IMAGE }} --push
--tag ${{ env.BUILD_IMAGE }}:${{ steps.extract_branch.outputs.branch }} --tag ${{ env.CACHE_IMAGE }} .