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