-
Notifications
You must be signed in to change notification settings - Fork 33
/
.gitlab-ci.yml
179 lines (167 loc) · 4.61 KB
/
.gitlab-ci.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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
stages:
- build
- deploy
before_script:
linux_x86-32_build:
stage: build
image: hpm/ubuntu:xenial-16.04-32
tags:
- linux
before_script:
- apt-get update
- apt-get -y install libx11-dev libxext-dev zlib1g-dev libjpeg-dev libpng-dev
script:
- cd src
- PLATFORM=x86_32 make -j16
artifacts:
paths:
- out-x86_32/*
expire_in: 2 week
linux_x86-64_build:
stage: build
image: hpm/ubuntu:xenial-16.04-64
tags:
- linux
before_script:
- apt-get update
- apt-get -y install libx11-dev libxext-dev zlib1g-dev libjpeg-dev libpng-dev
script:
- cd src
- make -j16
artifacts:
paths:
- out-x86_64/*
expire_in: 2 week
linux_armv7_build:
stage: build
image: hpm/ubuntu:xenial-16.04-64
tags:
- linux
script:
- cd src
- CROSS_COMPILE=/opt/gcc-linaro-7.5.0-2019.12-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- PLATFORM=armv7hf make -j16
artifacts:
paths:
- out-armv7hf/*
expire_in: 2 week
linux_aarch64_build:
stage: build
image: hpm/ubuntu:xenial-16.04-64
tags:
- linux
script:
- cd src
- CROSS_COMPILE=/opt/gcc-linaro-7.5.0-2019.12-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu- PLATFORM=aarch64 make -j16
artifacts:
paths:
- out-aarch64/*
expire_in: 2 week
linux_armv6_build:
stage: build
image: hpm/ubuntu:xenial-16.04-32
tags:
- linux
script:
- cd src
- CROSS_COMPILE=/opt/rpi-tools/arm-bcm2708/arm-bcm2708hardfp-linux-gnueabi/bin/arm-bcm2708hardfp-linux-gnueabi- PLATFORM=armv6 make
artifacts:
paths:
- out-armv6/*
expire_in: 2 week
linux_armv6tce_build:
stage: build
image: hpm/ubuntu:xenial-16.04-32
tags:
- linux
script:
- cd src
- CROSS_COMPILE=/opt/rpi-tools/arm-bcm2708/arm-bcm2708hardfp-linux-gnueabi/bin/arm-bcm2708hardfp-linux-gnueabi- PLATFORM=armv6tce make -j16
artifacts:
paths:
- out-armv6tce/*
expire_in: 2 week
deploy-hamspirit.at:
stage: deploy
image: hpm/ubuntu:xenial-16.04-64
tags:
- linux
before_script:
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
- mkdir -p ~/.ssh
- eval $(ssh-agent -s)
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- ssh-add <(echo "$STAGING_PRIVATE_KEY")
script:
- ci/deploy.sh
environment:
name: dxlaprs.hamspirit.at {production}
url: http://dxlaprs.hamspirit.at/branch-$CI_COMMIT_REF_NAME
only:
- master
deploy-github:
stage: deploy
image: hpm/ubuntu:xenial-16.04-64
dependencies: []
variables:
GIT_STRATEGY: clone
tags:
- linux
before_script:
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
- mkdir -p ~/.ssh
- eval $(ssh-agent -s)
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- ssh-add <(echo "$STAGING_PRIVATE_KEY")
script:
- git remote add github git@github.com:oe5hpm/dxlAPRS.git
- git branch
- git checkout master
- git push github HEAD:master
environment:
name: dxlaprs.hamspirit.at {production}
url: https://github.com/oe5hpm/dxlAPRS
only:
- master
deploy-dev-hamspirit.at:
stage: deploy
image: hpm/ubuntu:xenial-16.04-64
tags:
- linux
before_script:
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
- mkdir -p ~/.ssh
- eval $(ssh-agent -s)
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- ssh-add <(echo "$STAGING_PRIVATE_KEY")
script:
- ci/deploy.sh
environment:
name: dxlaprs.hamspirit.at {dev branch $CI_COMMIT_REF_NAME}
url: http://dxlaprs.hamspirit.at/branch-$CI_COMMIT_REF_NAME
on_stop: stop_dev-hamspirit.at
except:
- master
when: manual
stop_dev-hamspirit.at:
stage: deploy
image: hpm/ubuntu:xenial-16.04-64
dependencies: []
variables:
GIT_STRATEGY: none
tags:
- linux
before_script:
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
- mkdir -p ~/.ssh
- eval $(ssh-agent -s)
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- ssh-add <(echo "$STAGING_PRIVATE_KEY")
script:
- ssh -p 10022 aprsbuild@hamspirit.at "rm -r -f /home/aprsbuild/public_html/branch-$CI_COMMIT_REF_NAME"
when: manual
except:
- master
environment:
name: dxlaprs.hamspirit.at {dev branch $CI_COMMIT_REF_NAME}
url: http://dxlaprs.hamspirit.at/branch-$CI_COMMIT_REF_NAME
action: stop