| 1 |
name: CI |
| 2 |
|
| 3 |
on: |
| 4 |
push: |
| 5 |
branches-ignore: |
| 6 |
- 'main' |
| 7 |
|
| 8 |
env: |
| 9 |
BUILDER_VERSION: v0.9.92 |
| 10 |
BUILDER_SOURCE: releases |
| 11 |
BUILDER_HOST: https://d19elf31gohf1l.cloudfront.net |
| 12 |
PACKAGE_NAME: aws-c-http |
| 13 |
LINUX_BASE_IMAGE: ubuntu-18-x64 |
| 14 |
RUN: ${{ github.run_id }}-${{ github.run_number }} |
| 15 |
CRT_CI_ROLE: ${{ secrets.CRT_CI_ROLE_ARN }} |
| 16 |
AWS_DEFAULT_REGION: us-east-1 |
| 17 |
|
| 18 |
permissions: |
| 19 |
id-token: write |
| 20 |
|
| 21 |
jobs: |
| 22 |
linux-compat: |
| 23 |
runs-on: ubuntu-24.04 |
| 24 |
strategy: |
| 25 |
matrix: |
| 26 |
image: |
| 27 |
- manylinux1-x64 |
| 28 |
- manylinux1-x86 |
| 29 |
- manylinux2014-x64 |
| 30 |
- manylinux2014-x86 |
| 31 |
- al2-x64 |
| 32 |
- fedora-34-x64 |
| 33 |
- opensuse-leap |
| 34 |
- rhel8-x64 |
| 35 |
|
| 36 |
steps: |
| 37 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 38 |
with: |
| 39 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 40 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 41 |
|
| 42 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 43 |
run: | |
| 44 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 45 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ matrix.image }} build -p ${{ env.PACKAGE_NAME }} |
| 46 |
|
| 47 |
linux-compiler-compat: |
| 48 |
runs-on: ubuntu-24.04 |
| 49 |
strategy: |
| 50 |
matrix: |
| 51 |
compiler: |
| 52 |
- name: clang-6 |
| 53 |
- name: clang-8 |
| 54 |
- name: clang-9 |
| 55 |
- name: clang-10 |
| 56 |
- name: clang-11 |
| 57 |
- name: clang-15 |
| 58 |
- name: clang-17 |
| 59 |
- name: clang-latest |
| 60 |
- name: gcc-4.8 |
| 61 |
- name: gcc-5 |
| 62 |
- name: gcc-6 |
| 63 |
- name: gcc-7 |
| 64 |
- name: gcc-8 |
| 65 |
- name: gcc-11 |
| 66 |
- name: gcc-13 |
| 67 |
|
| 68 |
|
| 69 |
|
| 70 |
|
| 71 |
|
| 72 |
|
| 73 |
|
| 74 |
|
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
|
| 80 |
|
| 81 |
|
| 82 |
|
| 83 |
|
| 84 |
extra-build-flag: --cmake-extra=-DCMAKE_EXE_LINKER_FLAGS="-lresolv" |
| 85 |
steps: |
| 86 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 87 |
with: |
| 88 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 89 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 90 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 91 |
run: | |
| 92 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 93 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ env.LINUX_BASE_IMAGE }} build -p ${{ env.PACKAGE_NAME }} --compiler=${{ matrix.compiler.name }} ${{ matrix.compiler.extra-build-flag }} |
| 94 |
|
| 95 |
clang-sanitizers: |
| 96 |
runs-on: ubuntu-24.04 |
| 97 |
strategy: |
| 98 |
matrix: |
| 99 |
sanitizers: [",thread", ",address,undefined"] |
| 100 |
steps: |
| 101 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 102 |
with: |
| 103 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 104 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 105 |
|
| 106 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 107 |
run: | |
| 108 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 109 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ env.LINUX_BASE_IMAGE }} build -p ${{ env.PACKAGE_NAME }} --compiler=clang-11 --cmake-extra=-DENABLE_SANITIZERS=ON --cmake-extra=-DSANITIZERS="${{ matrix.sanitizers }}" |
| 110 |
|
| 111 |
linux-shared-libs: |
| 112 |
runs-on: ubuntu-24.04 |
| 113 |
steps: |
| 114 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 115 |
with: |
| 116 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 117 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 118 |
|
| 119 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 120 |
run: | |
| 121 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 122 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ env.LINUX_BASE_IMAGE }} build -p ${{ env.PACKAGE_NAME }} --cmake-extra=-DBUILD_SHARED_LIBS=ON |
| 123 |
|
| 124 |
byo-crypto: |
| 125 |
runs-on: ubuntu-24.04 |
| 126 |
steps: |
| 127 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 128 |
with: |
| 129 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 130 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 131 |
|
| 132 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 133 |
run: | |
| 134 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 135 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ env.LINUX_BASE_IMAGE }} build -p ${{ env.PACKAGE_NAME }} --cmake-extra=-DBYO_CRYPTO=ON |
| 136 |
|
| 137 |
|
| 138 |
|
| 139 |
|
| 140 |
downstream: |
| 141 |
runs-on: ubuntu-24.04 |
| 142 |
steps: |
| 143 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 144 |
with: |
| 145 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 146 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 147 |
|
| 148 |
- name: Build ${{ env.PACKAGE_NAME }} |
| 149 |
run: | |
| 150 |
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh |
| 151 |
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-ubuntu-22-x64 build downstream -p ${{ env.PACKAGE_NAME }} |
| 152 |
|
| 153 |
windows: |
| 154 |
runs-on: windows-2025 |
| 155 |
steps: |
| 156 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 157 |
with: |
| 158 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 159 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 160 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 161 |
run: | |
| 162 |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 163 |
python builder.pyz build -p ${{ env.PACKAGE_NAME }} |
| 164 |
|
| 165 |
windows-vc17: |
| 166 |
runs-on: windows-2025 |
| 167 |
strategy: |
| 168 |
matrix: |
| 169 |
arch: [x86, x64] |
| 170 |
steps: |
| 171 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 172 |
with: |
| 173 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 174 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 175 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 176 |
run: | |
| 177 |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 178 |
python builder.pyz build -p ${{ env.PACKAGE_NAME }} --target windows-${{ matrix.arch }} --compiler msvc-17 |
| 179 |
|
| 180 |
windows-shared-libs: |
| 181 |
runs-on: windows-2025 |
| 182 |
steps: |
| 183 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 184 |
with: |
| 185 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 186 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 187 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 188 |
run: | |
| 189 |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 190 |
python builder.pyz build -p ${{ env.PACKAGE_NAME }} --cmake-extra=-DBUILD_SHARED_LIBS=ON |
| 191 |
|
| 192 |
windows-app-verifier: |
| 193 |
runs-on: windows-2025 |
| 194 |
steps: |
| 195 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 196 |
with: |
| 197 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 198 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 199 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 200 |
run: | |
| 201 |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 202 |
python builder.pyz build -p ${{ env.PACKAGE_NAME }} run_tests=false --cmake-extra=-DBUILD_TESTING=ON |
| 203 |
- name: Run and check AppVerifier |
| 204 |
run: | |
| 205 |
python .\aws-c-http\build\deps\aws-c-common\scripts\appverifier_ctest.py --build_directory .\aws-c-http\build\aws-c-http |
| 206 |
|
| 207 |
macos: |
| 208 |
runs-on: macos-15 |
| 209 |
strategy: |
| 210 |
fail-fast: false |
| 211 |
matrix: |
| 212 |
eventloop: ["kqueue", "dispatch_queue"] |
| 213 |
steps: |
| 214 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 215 |
with: |
| 216 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 217 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 218 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 219 |
run: | |
| 220 |
python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder')" |
| 221 |
chmod a+x builder |
| 222 |
./builder build -p ${{ env.PACKAGE_NAME }} --cmake-extra=-DAWS_USE_APPLE_NETWORK_FRAMEWORK=${{ matrix.eventloop == 'dispatch_queue' && 'ON' || 'OFF' }} |
| 223 |
|
| 224 |
macos-x64: |
| 225 |
runs-on: macos-15-large |
| 226 |
steps: |
| 227 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 228 |
with: |
| 229 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 230 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 231 |
- name: Build ${{ env.PACKAGE_NAME }} + consumers |
| 232 |
run: | |
| 233 |
python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder')" |
| 234 |
chmod a+x builder |
| 235 |
./builder build -p ${{ env.PACKAGE_NAME }} |
| 236 |
|
| 237 |
localhost-test-linux: |
| 238 |
runs-on: ubuntu-24.04 |
| 239 |
steps: |
| 240 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 241 |
with: |
| 242 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 243 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 244 |
- name: Checkout |
| 245 |
uses: actions/checkout@v4 |
| 246 |
- name: Build and test |
| 247 |
run: | |
| 248 |
python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 249 |
python3 builder.pyz build -p aws-c-http --cmake-extra=-DENABLE_LOCALHOST_INTEGRATION_TESTS=ON --config Debug |
| 250 |
|
| 251 |
localhost-test-macos: |
| 252 |
runs-on: macos-15 |
| 253 |
strategy: |
| 254 |
fail-fast: false |
| 255 |
matrix: |
| 256 |
eventloop: ["kqueue", "dispatch_queue"] |
| 257 |
steps: |
| 258 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 259 |
with: |
| 260 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 261 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 262 |
- name: Checkout |
| 263 |
uses: actions/checkout@v4 |
| 264 |
- name: Build and test |
| 265 |
run: | |
| 266 |
python3 -m venv .venv |
| 267 |
source .venv/bin/activate |
| 268 |
python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 269 |
python3 builder.pyz build -p aws-c-http --cmake-extra=-DENABLE_LOCALHOST_INTEGRATION_TESTS=ON --cmake-extra=-DAWS_USE_APPLE_NETWORK_FRAMEWORK=${{ matrix.eventloop == 'dispatch_queue' && 'ON' || 'OFF' }} --config Debug |
| 270 |
|
| 271 |
localhost-test-win: |
| 272 |
runs-on: windows-2025 |
| 273 |
steps: |
| 274 |
- uses: aws-actions/configure-aws-credentials@v4 |
| 275 |
with: |
| 276 |
role-to-assume: ${{ env.CRT_CI_ROLE }} |
| 277 |
aws-region: ${{ env.AWS_DEFAULT_REGION }} |
| 278 |
- name: Checkout |
| 279 |
uses: actions/checkout@v4 |
| 280 |
- name: Build and test |
| 281 |
run: | |
| 282 |
python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')" |
| 283 |
python builder.pyz build -p aws-c-http --cmake-extra=-DENABLE_LOCALHOST_INTEGRATION_TESTS=ON --config Debug |