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