cfsetup.yaml 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303
  1. pinned_go: &pinned_go go=1.16.3-1
  2. pinned_go_fips: &pinned_go_fips go-fips=1.15.5-3
  3. build_dir: &build_dir /cfsetup_build
  4. default-flavor: buster
  5. stretch: &stretch
  6. build:
  7. build_dir: *build_dir
  8. builddeps:
  9. - *pinned_go_fips
  10. - build-essential
  11. post-cache:
  12. - export GOOS=linux
  13. - export GOARCH=amd64
  14. - export FIPS=true
  15. - make cloudflared
  16. build-deb:
  17. build_dir: *build_dir
  18. builddeps:
  19. - *pinned_go_fips
  20. - build-essential
  21. - fakeroot
  22. - rubygem-fpm
  23. post-cache:
  24. - export GOOS=linux
  25. - export GOARCH=amd64
  26. - export FIPS=true
  27. - make cloudflared-deb
  28. build-deb-arm64:
  29. build_dir: *build_dir
  30. builddeps:
  31. - *pinned_go
  32. - build-essential
  33. - fakeroot
  34. - rubygem-fpm
  35. post-cache:
  36. - export GOOS=linux
  37. - export GOARCH=arm64
  38. - make cloudflared-deb
  39. publish-deb:
  40. build_dir: *build_dir
  41. builddeps:
  42. - *pinned_go_fips
  43. - build-essential
  44. - fakeroot
  45. - rubygem-fpm
  46. - openssh-client
  47. post-cache:
  48. - export GOOS=linux
  49. - export GOARCH=amd64
  50. - export FIPS=true
  51. - make publish-deb
  52. release-linux-amd64:
  53. build_dir: *build_dir
  54. builddeps:
  55. - *pinned_go_fips
  56. - build-essential
  57. post-cache:
  58. - export GOOS=linux
  59. - export GOARCH=amd64
  60. - export FIPS=true
  61. - make release
  62. github-release-linux-amd64:
  63. build_dir: *build_dir
  64. builddeps:
  65. - *pinned_go_fips
  66. - build-essential
  67. - python3-setuptools
  68. - python3-pip
  69. pre-cache: &install_pygithub
  70. - pip3 install pygithub
  71. post-cache:
  72. - export GOOS=linux
  73. - export GOARCH=amd64
  74. - export FIPS=true
  75. - make github-release
  76. release-linux-armv6:
  77. build_dir: *build_dir
  78. builddeps:
  79. - *pinned_go
  80. - crossbuild-essential-armhf
  81. - gcc-arm-linux-gnueabihf
  82. post-cache:
  83. - export GOOS=linux
  84. - export GOARCH=arm
  85. - export CC=arm-linux-gnueabihf-gcc
  86. - make release
  87. github-release-linux-armv6:
  88. build_dir: *build_dir
  89. builddeps:
  90. - *pinned_go
  91. - crossbuild-essential-armhf
  92. - gcc-arm-linux-gnueabihf
  93. - python3-setuptools
  94. - python3-pip
  95. pre-cache: *install_pygithub
  96. post-cache:
  97. - export GOOS=linux
  98. - export GOARCH=arm
  99. - export CC=arm-linux-gnueabihf-gcc
  100. - make github-release
  101. release-linux-386:
  102. build_dir: *build_dir
  103. builddeps:
  104. - *pinned_go
  105. - gcc-multilib
  106. post-cache:
  107. - export GOOS=linux
  108. - export GOARCH=386
  109. - make release
  110. github-release-linux-386:
  111. build_dir: *build_dir
  112. builddeps:
  113. - *pinned_go
  114. - gcc-multilib
  115. - python3-setuptools
  116. - python3-pip
  117. pre-cache: *install_pygithub
  118. post-cache:
  119. - export GOOS=linux
  120. - export GOARCH=386
  121. - make github-release
  122. release-windows-amd64:
  123. build_dir: *build_dir
  124. builddeps:
  125. - *pinned_go
  126. - gcc-mingw-w64
  127. post-cache:
  128. - export GOOS=windows
  129. - export GOARCH=amd64
  130. - export CC=x86_64-w64-mingw32-gcc
  131. - make release
  132. github-release-windows-amd64:
  133. build_dir: *build_dir
  134. builddeps:
  135. - *pinned_go
  136. - gcc-mingw-w64
  137. - python3-setuptools
  138. - python3-pip
  139. pre-cache: *install_pygithub
  140. post-cache:
  141. - export GOOS=windows
  142. - export GOARCH=amd64
  143. - export CC=x86_64-w64-mingw32-gcc
  144. - make github-release
  145. release-windows-386:
  146. build_dir: *build_dir
  147. builddeps:
  148. - *pinned_go
  149. - gcc-mingw-w64
  150. post-cache:
  151. - export GOOS=windows
  152. - export GOARCH=386
  153. - export CC=i686-w64-mingw32-gcc-win32
  154. - make release
  155. github-release-windows-386:
  156. build_dir: *build_dir
  157. builddeps:
  158. - *pinned_go
  159. - gcc-mingw-w64
  160. - python3-setuptools
  161. - python3-pip
  162. pre-cache: *install_pygithub
  163. post-cache:
  164. - export GOOS=windows
  165. - export GOARCH=386
  166. - export CC=i686-w64-mingw32-gcc-win32
  167. - make github-release
  168. github-release-linux-arm64:
  169. build_dir: *build_dir
  170. builddeps:
  171. - *pinned_go
  172. - crossbuild-essential-armhf
  173. - g++-aarch64-linux-gnu
  174. - python3-setuptools
  175. - python3-pip
  176. pre-cache: *install_pygithub
  177. post-cache:
  178. - export GOOS=linux
  179. - export GOARCH=arm64
  180. - export CC=aarch64-linux-gnu-gcc
  181. - make github-release
  182. github-release-macos-amd64:
  183. build_dir: *build_dir
  184. builddeps:
  185. - *pinned_go
  186. - python3-setuptools
  187. - python3-pip
  188. pre-cache: *install_pygithub
  189. post-cache:
  190. - make github-mac-upload
  191. test:
  192. build_dir: *build_dir
  193. builddeps:
  194. - *pinned_go_fips
  195. - build-essential
  196. - gotest-to-teamcity
  197. pre-cache:
  198. - go get golang.org/x/tools/cmd/goimports
  199. - go get github.com/BurntSushi/go-sumtype
  200. post-cache:
  201. - export GOOS=linux
  202. - export GOARCH=amd64
  203. - export FIPS=true
  204. - export PATH="$HOME/go/bin:$PATH"
  205. - ./fmt-check.sh
  206. - make test | gotest-to-teamcity
  207. component-test:
  208. build_dir: *build_dir
  209. builddeps:
  210. - *pinned_go_fips
  211. - python3.7
  212. - python3-pip
  213. - python3-setuptools
  214. # procps installs the ps command which is needed in test_sysv_service because the init script
  215. # uses ps pid to determine if the agent is running
  216. - procps
  217. pre-cache-copy-paths:
  218. - component-tests/requirements.txt
  219. pre-cache:
  220. - sudo pip3 install --upgrade -r component-tests/requirements.txt
  221. post-cache:
  222. # Creates and routes a Named Tunnel for this build. Also constructs config file from env vars.
  223. - python3 component-tests/setup.py --type create
  224. - pytest component-tests
  225. # The Named Tunnel is deleted and its route unprovisioned here.
  226. - python3 component-tests/setup.py --type cleanup
  227. update-homebrew:
  228. builddeps:
  229. - openssh-client
  230. - s3cmd
  231. post-cache:
  232. - .teamcity/update-homebrew.sh
  233. github-message-release:
  234. build_dir: *build_dir
  235. builddeps:
  236. - *pinned_go
  237. - python3-setuptools
  238. - python3-pip
  239. pre-cache: *install_pygithub
  240. post-cache:
  241. - make github-message
  242. build-junos:
  243. build_dir: *build_dir
  244. builddeps:
  245. - *pinned_go
  246. - build-essential
  247. - python3
  248. - genisoimage
  249. - jetez
  250. pre-cache:
  251. - ln -s /usr/bin/genisoimage /usr/bin/mkisofs
  252. post-cache:
  253. - export GOOS=freebsd
  254. - export GOARCH=amd64
  255. - make cloudflared-junos
  256. publish-junos:
  257. build_dir: *build_dir
  258. builddeps:
  259. - *pinned_go
  260. - build-essential
  261. - python3
  262. - genisoimage
  263. - jetez
  264. - s4cmd
  265. pre-cache:
  266. - ln -s /usr/bin/genisoimage /usr/bin/mkisofs
  267. post-cache:
  268. - export GOOS=freebsd
  269. - export GOARCH=amd64
  270. - make publish-cloudflared-junos
  271. buster: *stretch
  272. bullseye: *stretch
  273. centos-7:
  274. publish-rpm:
  275. build_dir: *build_dir
  276. builddeps: &el7_builddeps
  277. - https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
  278. pre-cache:
  279. - yum install -y fakeroot
  280. - yum upgrade -y binutils-2.27-44.base.el7.x86_64
  281. - wget https://golang.org/dl/go1.16.3.linux-amd64.tar.gz -P /tmp/
  282. - tar -C /usr/local -xzf /tmp/go1.16.3.linux-amd64.tar.gz
  283. post-cache:
  284. - export PATH=$PATH:/usr/local/go/bin
  285. - export GOOS=linux
  286. - export GOARCH=amd64
  287. - make publish-rpm
  288. build-rpm:
  289. build_dir: *build_dir
  290. builddeps: *el7_builddeps
  291. pre-cache:
  292. - yum install -y fakeroot
  293. - yum upgrade -y binutils-2.27-44.base.el7.x86_64
  294. - wget https://golang.org/dl/go1.16.3.linux-amd64.tar.gz -P /tmp/
  295. - tar -C /usr/local -xzf /tmp/go1.16.3.linux-amd64.tar.gz
  296. post-cache:
  297. - export PATH=$PATH:/usr/local/go/bin
  298. - export GOOS=linux
  299. - export GOARCH=amd64
  300. - make cloudflared-rpm