forked from kruize/autotune
-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (55 loc) · 1.89 KB
/
test-on-push.yaml
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
name: Test on Push
# Controls when the action will run.
on:
# Triggers the workflow on push event but only for the master branch
push:
branches: [ master ]
paths-ignore:
- 'docs/**'
- 'design/**'
- 'examples/**'
- 'extensions/**'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
# This workflow contains a single job called "deploy"
deploy:
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- name: Setup Minikube
uses: manusa/[email protected]
with:
minikube version: 'v1.16.0'
kubernetes version: 'v1.19.2'
- name: Start minikube
run: |
kubectl cluster-info
kubectl get pods -n kube-system
- name: Build autotune
run: |
echo Build autotune
./build.sh -i autotune_operator:test -o autotune_optuna:test
docker images | grep autotune
- name: docker login
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Docker Push
run: |
docker tag autotune_operator:test kruize/autotune_operator:test
docker tag autotune_optuna:test kruize/autotune_optuna:test
docker push kruize/autotune_operator:test
docker push kruize/autotune_optuna:test
- name: Install Prometheus on minikube
run: |
echo Install Prometheus on minikube
cd scripts
./prometheus_on_minikube.sh -as
- name: Deploy autotune
run: |
echo Deploy autotune
./deploy.sh -c minikube -i kruize/autotune_operator:test -o kruize/autotune_optuna:test