add CI job #1
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: Docker | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
workflow_dispatch: | |
# automatically cancel in-progress builds if another commit is pushed | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
name: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: dockerfile-cli | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/dockerfile-python | |
- name: dockerfile-r | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/dockerfile-r | |
- name: dockerfile-python | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/dockerfile-python | |
- name: dockerfile.gpu | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/gpu/dockerfile.gpu | |
- name: dockerfile-cli-only.gpu | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/gpu/dockerfile-cli-only.gpu | |
- name: dockerfile-cli-only-distroless.gpu | |
shell: | |
docker build \ | |
--build-arg LIGHTGBM_GIT_REF=${{ github.ref }} \ | |
- < ./docker/gpu/dockerfile-cli-only-distroless.gpu | |
all-docker-jobs-successful: | |
if: always() | |
runs-on: ubuntu-latest | |
needs: [build] | |
steps: | |
- name: Note that all tests succeeded | |
uses: re-actors/[email protected] | |
with: | |
jobs: ${{ toJSON(needs) }} |