Skip to content

Commit 62c3e4e

Browse files
authored
[CI] Separate release build and nightly build.
1 parent 9c6f764 commit 62c3e4e

6 files changed

Lines changed: 130 additions & 34 deletions

File tree

.github/ISSUE_TEMPLATE/20-documentation.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
2-
name: Improvements or additions to documentation
3-
about: Use this template for a documentation/building/installation issue.
2+
name: Needs help for installation or documentation
3+
about: Use this template for an installation/documentation issue.
44

55
---
66

77
# Summary
88

9-
# Building/Installation environment
9+
# Installation environment
1010
- GPU model and memory:
1111
- OS Platform:
1212
- Docker version:
Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
name: Tests with TensorFlow 1.14 on CPU
1+
name: Nightly Build on CPU for Tensorflow 1.14
22

33
on: workflow_dispatch
44

55
env:
66
IMAGE: registry.cn-shanghai.aliyuncs.com/pai-dlc/hybridbackend:developer-tensorflow1.14-manylinux_2_24-py3.6
7-
JOBNAME: hbci-tf114-cpu-${{ github.run_id }}
8-
PODNAME: hbci-tf114-cpu-${{ github.run_id }}-chief-0
7+
JOBNAME: hbci-${{ github.run_id }}
8+
PODNAME: hbci-${{ github.run_id }}-chief-0
99
ARROW_CACHE_URL_PREFIX: ${{ secrets.ARROW_CACHE_URL_PREFIX }}
1010

1111
jobs:
@@ -17,30 +17,26 @@ jobs:
1717
uses: actions/checkout@v2
1818
with:
1919
submodules: 'true'
20-
- name: Configure Environment
20+
- name: Setup Environment
2121
uses: aliyun/ack-set-context@v1
2222
with:
2323
access-key-id: "${{ secrets.ACCESS_KEY_ID }}"
2424
access-key-secret: "${{ secrets.ACCESS_KEY_SECRET }}"
2525
cluster-id: "${{ secrets.ACK_CLUSTER_ID }}"
26-
- name: Setup Environment
26+
- name: Upload
2727
run: |-
28-
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=tensorflow1.14-py3.6 && \
28+
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=cpu-legacy && \
2929
cibuild/upload ${PODNAME} ../cibuild && \
3030
kubectl exec -it ${PODNAME} -- arrow/download.sh ${ARROW_CACHE_URL_PREFIX}
31-
- name: Nightly Build
32-
if: github.event_name != 'push' || ! startsWith(github.ref, 'refs/tags')
31+
- name: Build
3332
run: |-
3433
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu-legacy-nightly HYBRIDBACKEND_WHEEL_BUILD=rc${{ github.run_id }}' && \
3534
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
36-
- name: Release Build
37-
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
35+
- name: Test
3836
run: |-
39-
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu-legacy HYBRIDBACKEND_WHEEL_REQUIRES="tensorflow>=1.14,<1.15"' && \
40-
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
41-
- name: Check
37+
kubectl exec -it ${PODNAME} -- make cpu_test
38+
- name: Download
4239
run: |-
43-
kubectl exec -it ${PODNAME} -- make cpu_test && \
4440
kubectl exec -it ${PODNAME} -- tar -cf dist.tar dist/ && \
4541
kubectl cp ${PODNAME}:dist.tar ./dist.tar && \
4642
tar -xf ./dist.tar
@@ -50,7 +46,7 @@ jobs:
5046
skip_existing: true
5147
user: __token__
5248
password: ${{ secrets.PYPI_API_TOKEN }}
53-
- name: Cleanup Emvironment
49+
- name: Cleanup Environment
5450
if: always()
5551
run: |-
5652
helm uninstall ${JOBNAME}

.github/workflows/cpu-legacy.yaml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Build on CPU for Tensorflow 1.14
2+
3+
on: workflow_dispatch
4+
5+
env:
6+
IMAGE: registry.cn-shanghai.aliyuncs.com/pai-dlc/hybridbackend:developer-tensorflow1.14-manylinux_2_24-py3.6
7+
JOBNAME: hbci-${{ github.run_id }}
8+
PODNAME: hbci-${{ github.run_id }}-chief-0
9+
ARROW_CACHE_URL_PREFIX: ${{ secrets.ARROW_CACHE_URL_PREFIX }}
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
environment: TensorFlow 1.14
15+
steps:
16+
- name: Checkout Code
17+
uses: actions/checkout@v2
18+
with:
19+
submodules: 'true'
20+
- name: Setup Environment
21+
uses: aliyun/ack-set-context@v1
22+
with:
23+
access-key-id: "${{ secrets.ACCESS_KEY_ID }}"
24+
access-key-secret: "${{ secrets.ACCESS_KEY_SECRET }}"
25+
cluster-id: "${{ secrets.ACK_CLUSTER_ID }}"
26+
- name: Upload
27+
run: |-
28+
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=cpu-legacy && \
29+
cibuild/upload ${PODNAME} ../cibuild && \
30+
kubectl exec -it ${PODNAME} -- arrow/download.sh ${ARROW_CACHE_URL_PREFIX}
31+
- name: Build
32+
run: |-
33+
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu-legacy HYBRIDBACKEND_WHEEL_REQUIRES="tensorflow>=1.14,<1.15"' && \
34+
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
35+
- name: Test
36+
run: |-
37+
kubectl exec -it ${PODNAME} -- make cpu_test
38+
- name: Download
39+
run: |-
40+
kubectl exec -it ${PODNAME} -- tar -cf dist.tar dist/ && \
41+
kubectl cp ${PODNAME}:dist.tar ./dist.tar && \
42+
tar -xf ./dist.tar
43+
- name: Publish
44+
uses: pypa/gh-action-pypi-publish@release/v1
45+
with:
46+
skip_existing: true
47+
user: __token__
48+
password: ${{ secrets.PYPI_API_TOKEN }}
49+
- name: Cleanup Environment
50+
if: always()
51+
run: |-
52+
helm uninstall ${JOBNAME}

.github/workflows/cpu-nightly.yaml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Nightly Build on CPU
2+
3+
on: [workflow_dispatch, push]
4+
5+
env:
6+
IMAGE: registry.cn-shanghai.aliyuncs.com/pai-dlc/hybridbackend:developer-tensorflow1.15-manylinux_2_24-py3.6
7+
JOBNAME: hbci-${{ github.run_id }}
8+
PODNAME: hbci-${{ github.run_id }}-chief-0
9+
ARROW_CACHE_URL_PREFIX: ${{ secrets.ARROW_CACHE_URL_PREFIX }}
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
environment: TensorFlow 1.15
15+
steps:
16+
- name: Checkout Code
17+
uses: actions/checkout@v2
18+
with:
19+
submodules: 'true'
20+
- name: Setup Environment
21+
uses: aliyun/ack-set-context@v1
22+
with:
23+
access-key-id: "${{ secrets.ACCESS_KEY_ID }}"
24+
access-key-secret: "${{ secrets.ACCESS_KEY_SECRET }}"
25+
cluster-id: "${{ secrets.ACK_CLUSTER_ID }}"
26+
- name: Upload
27+
run: |-
28+
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=cpu && \
29+
cibuild/upload ${PODNAME} ../cibuild && \
30+
kubectl exec -it ${PODNAME} -- arrow/download.sh ${ARROW_CACHE_URL_PREFIX}
31+
- name: Build
32+
run: |-
33+
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu-nightly HYBRIDBACKEND_WHEEL_BUILD=rc${{ github.run_id }}' && \
34+
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
35+
- name: Test
36+
run: |-
37+
kubectl exec -it ${PODNAME} -- make lint cpu_test
38+
- name: Download
39+
run: |-
40+
kubectl exec -it ${PODNAME} -- tar -cf dist.tar dist/ && \
41+
kubectl cp ${PODNAME}:dist.tar ./dist.tar && \
42+
tar -xf ./dist.tar
43+
- name: Publish
44+
uses: pypa/gh-action-pypi-publish@release/v1
45+
with:
46+
skip_existing: true
47+
user: __token__
48+
password: ${{ secrets.PYPI_API_TOKEN }}
49+
- name: Cleanup Environment
50+
if: always()
51+
run: |-
52+
helm uninstall ${JOBNAME}

.github/workflows/tensorflow1.15-py3.6-cibuild.yaml renamed to .github/workflows/cpu.yaml

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
name: Tests with TensorFlow 1.15 on CPU
1+
name: Build on CPU
22

33
on: workflow_dispatch
44

55
env:
66
IMAGE: registry.cn-shanghai.aliyuncs.com/pai-dlc/hybridbackend:developer-tensorflow1.15-manylinux_2_24-py3.6
7-
JOBNAME: hbci-tf115-cpu-${{ github.run_id }}
8-
PODNAME: hbci-tf115-cpu-${{ github.run_id }}-chief-0
7+
JOBNAME: hbci-${{ github.run_id }}
8+
PODNAME: hbci-${{ github.run_id }}-chief-0
99
ARROW_CACHE_URL_PREFIX: ${{ secrets.ARROW_CACHE_URL_PREFIX }}
1010

1111
jobs:
@@ -17,30 +17,26 @@ jobs:
1717
uses: actions/checkout@v2
1818
with:
1919
submodules: 'true'
20-
- name: Configure Environment
20+
- name: Setup Environment
2121
uses: aliyun/ack-set-context@v1
2222
with:
2323
access-key-id: "${{ secrets.ACCESS_KEY_ID }}"
2424
access-key-secret: "${{ secrets.ACCESS_KEY_SECRET }}"
2525
cluster-id: "${{ secrets.ACK_CLUSTER_ID }}"
26-
- name: Setup Environment
26+
- name: Upload
2727
run: |-
28-
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=tensorflow1.15-py3.6 && \
28+
helm install ${JOBNAME} cibuild/ --set image=${IMAGE} --set tag=cpu && \
2929
cibuild/upload ${PODNAME} ../cibuild && \
3030
kubectl exec -it ${PODNAME} -- arrow/download.sh ${ARROW_CACHE_URL_PREFIX}
31-
- name: Nightly Build
32-
if: github.event_name != 'push' || ! startsWith(github.ref, 'refs/tags')
33-
run: |-
34-
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu-nightly HYBRIDBACKEND_WHEEL_BUILD=rc${{ github.run_id }}' && \
35-
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
36-
- name: Release Build
37-
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
31+
- name: Build
3832
run: |-
3933
kubectl exec -it ${PODNAME} -- sh -c 'make -j32 HYBRIDBACKEND_WHEEL_ALIAS=-cpu HYBRIDBACKEND_WHEEL_REQUIRES="tensorflow>=1.15,<2.0"' && \
4034
kubectl exec -it ${PODNAME} -- cibuild/repair_dist
41-
- name: Check
35+
- name: Test
36+
run: |-
37+
kubectl exec -it ${PODNAME} -- make lint cpu_test
38+
- name: Download
4239
run: |-
43-
kubectl exec -it ${PODNAME} -- make lint cpu_test && \
4440
kubectl exec -it ${PODNAME} -- tar -cf dist.tar dist/ && \
4541
kubectl cp ${PODNAME}:dist.tar ./dist.tar && \
4642
tar -xf ./dist.tar

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# HybridBackend
22

3-
![Tensorflow 1.15 CPU CI Build Badge](https://github.com/alibaba/HybridBackend/actions/workflows/.github/workflows/tensorflow1.15-py3.6-cibuild.yaml/badge.svg)
3+
[![Nightly Build on CPU](https://github.com/alibaba/HybridBackend/actions/workflows/cpu-nightly.yaml/badge.svg)](https://github.com/alibaba/HybridBackend/actions/workflows/cpu-nightly.yaml)
44
[![Documentation Status](https://readthedocs.org/projects/hybridbackend/badge/?version=latest)](https://hybridbackend.readthedocs.io/en/latest/?badge=latest)
55

66
## Introduction

0 commit comments

Comments
 (0)