This repository was archived by the owner on Apr 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
90 lines (74 loc) · 2.75 KB
/
docker_images.yml
File metadata and controls
90 lines (74 loc) · 2.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
name: Docker Image CI
on:
push:
branches: [ main ]
paths:
- 'docker/**'
- '.github/workflows/docker_images.yml'
pull_request:
branches: [ main ]
paths:
- 'docker/**'
- '.github/workflows/docker_images.yml'
workflow_dispatch:
inputs:
name:
description: 'Reason'
required: false
default: '...'
jobs:
linux_container_build:
runs-on: ubuntu-latest
strategy:
matrix:
dockerfile:
- docker/lightgbm-v3.2.1/linux_cpu_mpi_build.dockerfile
- docker/lightgbm-v3.2.1/linux_cpu_mpi_pip.dockerfile
- docker/lightgbm-v3.2.1/linux_cuda_build.dockerfile
- docker/lightgbm-v3.2.1/linux_gpu_build.dockerfile
- docker/lightgbm-v3.2.1/linux_gpu_pip.dockerfile
- docker/lightgbm-v3.3.0/linux_cpu_mpi_build.dockerfile
- docker/lightgbm-v3.3.0/linux_cpu_mpi_pip.dockerfile
- docker/lightgbm-custom/v321_patch_cpu_mpi_build.dockerfile
- src/scripts/training/lightgbm_python/default.dockerfile
- src/scripts/inferencing/lightgbm_python/default.dockerfile
- src/scripts/inferencing/lightgbm_c_api/default.dockerfile
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Query Git branch name
uses: petehouston/github-actions-query-branch-name@v1.2
- name: Check branch name
run: |-
echo "GIT_BRANCH_NAME = $GIT_BRANCH_NAME"
echo "GIT_BRANCH_NAME_HEAD = $GIT_BRANCH_NAME_BEAD"
echo "GIT_BRANCH_NAME_BASE = $GIT_BRANCH_NAME_BASE"
echo "Branch name: ${{ steps.queryBranch.outputs.git_branch_name }}"
echo "Branch name: ${{ steps.queryBranch.outputs.git_branch_name_head }}"
echo "Branch name: ${{ steps.queryBranch.outputs.git_branch_name_base }}"
- uses: marceloprado/has-changed-path@v1
id: dockerfile-changed
with:
paths: ${{ matrix.dockerfile}}
- name: Build the Docker image
if: steps.dockerfile-changed.outputs.changed == 'true'
run: docker build . --file ${{ matrix.dockerfile }} --tag temp:$(date +%s) --build-arg lightgbm_benchmark_branch=$GIT_BRANCH_NAME
windows_container_build:
runs-on: windows-latest
strategy:
matrix:
dockerfile:
- docker/lightgbm-v3.2.1/windows_cpu_pip.dockerfile
- docker/lightgbm-v3.3.0/windows_cpu_pip.dockerfile
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: marceloprado/has-changed-path@v1
id: dockerfile-changed
with:
paths: docker/${{ matrix.dockerfile}}
- name: Build the Docker image
if: steps.dockerfile-changed.outputs.changed == 'true'
run: docker build . --file ${{ matrix.dockerfile }} --tag temp:$(date +%s)