forked from osmhpi/metalfs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.drone.yml
140 lines (126 loc) · 3.24 KB
/
.drone.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
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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
---
kind: pipeline
name: sdk
platform:
arch: amd64
steps:
- name: docker/build-base
image: docker
volumes:
- name: dockersock
path: /var/run/docker.sock
commands:
- apk add --no-cache make git
- sh -c "scripts/docker_build_sdk_base"
- name: metalfs/software
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- mkdir build && cd build && cmake -DOPTION_BUILD_EXAMPLES=ON -DOPTION_BUILD_DOCS=ON .. && make -j4
- name: metalfs/filesystem-test
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd build && ./metal-filesystem-test
- name: metalfs/pipeline-test
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd build && ./metal-pipeline-test
- name: metalfs/action
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd example/src
- npm install --production
- bash -c "make hw_project"
- name: metalfs/testbench
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd example/src
- bash -c "make test_target"
- name: metalfs/example-sim
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd example/src
- bash -c "make model"
- echo "$DRONE_WORKSPACE/build/example-test" > $DRONE_WORKSPACE/example/src/build/WebPACK_Sim/snap/hardware/sim/testlist.sh
- chmod +x $DRONE_WORKSPACE/example/src/build/WebPACK_Sim/snap/hardware/sim/testlist.sh
- cd $DRONE_WORKSPACE/example/src/build/WebPACK_Sim/snap/hardware/sim/xsim
- ../run_sim -explore -list testlist.sh -noaet
- name: docker/build-sdk
image: docker
volumes:
- name: dockersock
path: /var/run/docker.sock
commands:
- apk add --no-cache make git
- sh -c "scripts/docker_build_sdk"
- name: docker/push
image: docker
volumes:
- name: dockersock
path: /var/run/docker.sock
commands:
- apk add --no-cache make git
- sh -c "scripts/docker_push_sdk"
environment:
USERNAME:
from_secret: docker_username
PASSWORD:
from_secret: docker_password
when:
event:
- tag
- name: docker/push-latest
image: docker
volumes:
- name: dockersock
path: /var/run/docker.sock
commands:
- apk add --no-cache make git
- sh -c "scripts/docker_push_latest_sdk"
environment:
USERNAME:
from_secret: docker_username
PASSWORD:
from_secret: docker_password
when:
branch:
- master
event:
exclude:
- pull_request
- name: docs/prepare
image: metalfs/sdk-base:latest
pull: if-not-exists
commands:
- cd build/docs/sphinx
- rm -rf .buildinfo .doctrees
- touch .nojekyll
when:
branch:
- master
event:
exclude:
- pull_request
- name: docs/publish
image: plugins/gh-pages
settings:
username:
from_secret: github_username
password:
from_secret: github_password
pages_directory: build/docs/sphinx
when:
branch:
- master
event:
exclude:
- pull_request
volumes:
- name: dockersock
host:
path: /var/run/docker.sock