2021-01-16 00:23:36 +01:00
|
|
|
name: PR Checks
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches: master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build-ckan-2-9:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
|
|
|
|
- name: Cache Docker layers
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
2021-01-16 02:42:37 +01:00
|
|
|
path: |
|
|
|
|
/tmp/.buildx-cache-alpine-2-9
|
|
|
|
/tmp/.buildx-cache-ubuntu-2-9
|
|
|
|
key: ${{ runner.os }}-buildx-2-9-${{ github.sha }}
|
2021-01-16 00:23:36 +01:00
|
|
|
restore-keys: |
|
2021-01-16 02:42:37 +01:00
|
|
|
${{ runner.os }}-buildx-2-9
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Alpine image
|
|
|
|
id: alpine
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.9/Dockerfile)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.9 alpine
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.9
|
|
|
|
file: ./images/ckan/2.9/Dockerfile
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.alpine.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-alpine-2-9
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-alpine-2-9
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Ubuntu image
|
|
|
|
id: ubuntu
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.9/Dockerfile.focal)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.9 ubuntu
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.9
|
|
|
|
file: ./images/ckan/2.9/Dockerfile.focal
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.ubuntu.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-ubuntu-2-9
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-ubuntu-2-9
|
2021-01-16 00:23:36 +01:00
|
|
|
|
|
|
|
build-ckan-2-8:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
|
|
|
|
- name: Cache Docker layers
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
2021-01-16 02:42:37 +01:00
|
|
|
path: |
|
|
|
|
/tmp/.buildx-cache-alpine-2-8
|
|
|
|
/tmp/.buildx-cache-ubuntu-2-8
|
|
|
|
key: ${{ runner.os }}-buildx-2-8-${{ github.sha }}
|
2021-01-16 00:23:36 +01:00
|
|
|
restore-keys: |
|
2021-01-16 02:42:37 +01:00
|
|
|
${{ runner.os }}-buildx-2-8
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Alpine image
|
|
|
|
id: alpine
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.8/Dockerfile)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.8 alpine
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.8
|
|
|
|
file: ./images/ckan/2.8/Dockerfile
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.alpine.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-alpine-2-8
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-alpine-2-8
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Ubuntu image
|
|
|
|
id: ubuntu
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.8/Dockerfile.focal)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.8 ubuntu
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.8
|
|
|
|
file: ./images/ckan/2.8/Dockerfile.focal
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.ubuntu.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-ubuntu-2-8
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-ubuntu-2-8
|
2021-01-16 00:23:36 +01:00
|
|
|
|
|
|
|
build-ckan-2-7:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
|
|
|
|
- name: Cache Docker layers
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
2021-01-16 02:42:37 +01:00
|
|
|
path: |
|
|
|
|
/tmp/.buildx-cache-alpine-2-7
|
|
|
|
/tmp/.buildx-cache-ubuntu-2-7
|
|
|
|
key: ${{ runner.os }}-buildx-2-7-${{ github.sha }}
|
2021-01-16 00:23:36 +01:00
|
|
|
restore-keys: |
|
2021-01-16 02:42:37 +01:00
|
|
|
${{ runner.os }}-buildx-2-7
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Alpine image
|
|
|
|
id: alpine
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.7/Dockerfile)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.7 alpine
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.7
|
|
|
|
file: ./images/ckan/2.7/Dockerfile
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.alpine.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-alpine-2-7
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-alpine-2-7
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for Ubuntu image
|
|
|
|
id: ubuntu
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/ckan/2.7/Dockerfile.focal)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN 2.7 ubuntu
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/ckan/2.7
|
|
|
|
file: ./images/ckan/2.7/Dockerfile.focal
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckan:${{ steps.ubuntu.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-ubuntu-2-7
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-ubuntu-2-7
|
2021-01-16 00:23:36 +01:00
|
|
|
|
|
|
|
build-ckan-datapusher:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
|
|
|
|
- name: Cache Docker layers
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
2021-01-16 02:42:37 +01:00
|
|
|
path: /tmp/.buildx-cache-datapusher
|
|
|
|
key: ${{ runner.os }}-buildx-datapusher-${{ github.sha }}
|
2021-01-16 00:23:36 +01:00
|
|
|
restore-keys: |
|
2021-01-16 02:42:37 +01:00
|
|
|
${{ runner.os }}-buildx-datapusher
|
2021-01-16 00:23:36 +01:00
|
|
|
|
2021-01-16 01:35:41 +01:00
|
|
|
- name: Get docker tag for datapusher image
|
|
|
|
id: datapusher
|
|
|
|
run: |
|
|
|
|
echo "::set-output name=IMAGE_TAG::$(awk -F '=' '/IMAGE_TAG/{print $2}' ./images/datapusher/Dockerfile)"
|
|
|
|
|
2021-01-16 00:23:36 +01:00
|
|
|
- name: Build CKAN datapusher
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
context: ./images/datapusher
|
|
|
|
file: ./images/datapusher/Dockerfile
|
|
|
|
push: false
|
2021-01-16 01:35:41 +01:00
|
|
|
tags: keitaro/ckandatapusher:${{ steps.datapusher.outputs.IMAGE_TAG }}
|
2021-01-16 02:42:37 +01:00
|
|
|
cache-from: type=local,src=/tmp/.buildx-cache-datapusher
|
|
|
|
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-datapusher
|