diff --git a/.github/workflows/containers.yml b/.github/workflows/containers.yml index 5a28941..ee8fbb6 100644 --- a/.github/workflows/containers.yml +++ b/.github/workflows/containers.yml @@ -18,7 +18,7 @@ env: jobs: on-success: name: Build, Test and Push Docker Image to DockerHub - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }} permissions: packages: write @@ -75,12 +75,12 @@ jobs: push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} -# cache-from: type=gha -# cache-to: type=gha,mode=max + cache-from: type=gha + cache-to: type=gha,mode=max platforms: linux/arm64, linux/amd64 - + on-failure: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 if: ${{ github.event.workflow_run.conclusion == 'failure' }} steps: - name: Print Test Fail diff --git a/Dockerfile b/Dockerfile index dabd36e..5edeec5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -101,6 +101,8 @@ ENV TZ=${TZ} \ python3-yaml \ ${ADD_DEB_PACKAGES}" +WORKDIR /pygeoapi +ADD . /pygeoapi # Install operating system dependencies RUN \ @@ -117,15 +119,10 @@ RUN \ && mkdir /schemas.opengis.net \ && curl -O http://schemas.opengis.net/SCHEMAS_OPENGIS_NET.zip \ && unzip ./SCHEMAS_OPENGIS_NET.zip "ogcapi/*" -d /schemas.opengis.net \ - && rm -f ./SCHEMAS_OPENGIS_NET.zip - -# Install pygeoapi -WORKDIR /pygeoapi -ADD . /pygeoapi -RUN \ + && rm -f ./SCHEMAS_OPENGIS_NET.zip \ # Install remaining pygeoapi deps - pip3 install -r requirements-docker.txt \ + && pip3 install -r requirements-docker.txt \ # Install pygeoapi && pip3 install -e . \