subsurface/.github/workflows/dockerimages.yml
Anton Lundin 6612297022 GitHub Actions: let CI build docker images
This create a GitHub Actions workflow to build the docker images we use in our
CI workflows.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
2019-11-28 11:12:59 -08:00

72 lines
2.2 KiB
YAML

name: Docker Image CI
on:
push:
branches:
- master
paths:
- scripts/docker/android-build-container/Dockerfile
- scripts/docker/mxe-build-container/Dockerfile
- scripts/docker/trusty-qt512/Dockerfile
jobs:
android-build-container:
runs-on: ubuntu-latest
env:
VERSION: 5.13.01
steps:
- uses: actions/checkout@v1
- name: Get our pre-reqs
run: |
cd scripts/docker/android-build-container
bash download.sh
sed -ie 's/^sudo/#sudo/' setup-docker.sh
bash setup-docker.sh
- name: Build the Docker image
run: docker build ./scripts/docker/android-build-container/ --tag docker.pkg.github.com/${GITHUB_REPOSITORY,,}/android-build-container:${VERSION}
- name: Push the Docker image
run: |
docker login docker.pkg.github.com -u ${GITHUB_REPOSITORY/\/*/} -p ${{ secrets.GITHUB_TOKEN }}
docker push docker.pkg.github.com/${GITHUB_REPOSITORY,,}/android-build-container:${VERSION}
mxe-build-container:
runs-on: ubuntu-latest
timeout-minutes: 720
env:
VERSION: 0.9
steps:
- uses: actions/checkout@v1
- name: Build the Docker image
run: docker build ./scripts/docker/mxe-build-container/ --tag docker.pkg.github.com/${GITHUB_REPOSITORY,,}/mxe-build-container:${VERSION}
- name: Push the Docker image
run: |
docker login docker.pkg.github.com -u ${GITHUB_REPOSITORY/\/*/} -p ${{ secrets.GITHUB_TOKEN }}
docker push docker.pkg.github.com/${GITHUB_REPOSITORY,,}/mxe-build-container:${VERSION}
trusty-qt512:
runs-on: ubuntu-latest
env:
VERSION: 0.7
steps:
- uses: actions/checkout@v1
- name: Get our pre-reqs
run: |
cd scripts/docker/trusty-qt512
bash getpackages.sh
- name: Build the Docker image
run: docker build ./scripts/docker/trusty-qt512/ --tag docker.pkg.github.com/${GITHUB_REPOSITORY,,}/trusty-qt512:${VERSION}
- name: Push the Docker image
run: |
docker login docker.pkg.github.com -u ${GITHUB_REPOSITORY/\/*/} -p ${{ secrets.GITHUB_TOKEN }}
docker push docker.pkg.github.com/${GITHUB_REPOSITORY,,}/trusty-qt512:${VERSION}