-
Notifications
You must be signed in to change notification settings - Fork 5
41 lines (41 loc) · 1.43 KB
/
main.yml
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
name: Trigger test runs
on:
- pull_request
jobs:
job1:
runs-on: ubuntu-latest
name: Test run as argo workflow on minikube
steps:
- uses: actions/checkout@v2
- name: Start a minikube cluster
run: |
minikube start
n=0; until ((n >= 60)); do kubectl -n default get serviceaccount default -o name && break; n=$((n + 1)); sleep 1; done; ((n < 60))
- name: Set up persistent volume and storage pod
run: |
kubectl apply -f volumes.yaml
- name: Set up argo
run: |
kubectl create ns argo
kubectl apply -n argo -f https://raw.githubusercontent.com/argoproj/argo-workflows/stable/manifests/quick-start-postgres.yaml
curl -sLO https://github.com/argoproj/argo-workflows/releases/download/v3.1.1/argo-linux-amd64.gz
gunzip argo-linux-amd64.gz
chmod +x argo-linux-amd64
sudo mv ./argo-linux-amd64 /usr/local/bin/argo
argo version
- name: Submit the argo test workflow
run: |
argo submit -n argo --wait argo-workflow.yaml
- name: Check the output
run: |
argo logs -n argo @latest
mkdir outputs
echo Copy file with kubectl cp task-pv-pod:/mnt/data/ outputs/ :
kubectl cp task-pv-pod:/mnt/data/ outputs/
echo ls -l :
ls -l
- name: Upload the ouput as a github artifact
uses: actions/upload-artifact@v2
with:
name: output
path: outputs/