fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #72883 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum49cae55760d

1.44.0
22.2 KiB710 linesraw
1######################################################
2#   WARNING! Action needed when changing this file   #
3######################################################
4
5# Due to GitHub Actions limitations, we can't use YAML Anchors directly in the
6# CI configuration stored on the repository. To work around that this file is
7# expanded by a tool in the repository, and the expansion is committed as well.
8#
9# After you make any change to the file you'll need to run this command:
10#
11#   ./x.py run src/tools/expand-yaml-anchors
12#
13# ...and commit the file it updated in addition to this one. If you forget this
14# step CI will fail.
15
16---
17
18###############################
19#   YAML Anchors Definition   #
20###############################
21
22# This key contains most of the YAML anchors that will be used later in the
23# document. YAML anchors allows us to greatly reduce duplication inside the CI
24# configuration by reusing parts of the configuration.
25#
26# YAML anchors work by defining an anchor with `&anchor-name` and reusing its
27# content in another place with `*anchor-name`. The special `<<` map key merges
28# the content of the map with the content of the anchor (or list of anchors).
29#
30# The expand-yaml-anchors tool will automatically remove this block from the
31# output YAML file.
32x--expand-yaml-anchors--remove:
33
34  - &shared-ci-variables
35    CI_JOB_NAME: ${{ matrix.name }}
36
37  - &public-variables
38    SCCACHE_BUCKET: rust-lang-gha-caches
39    TOOLSTATE_REPO: https://github.com/pietroalbini/rust-toolstate
40
41  - &prod-variables
42    SCCACHE_BUCKET: rust-lang-gha-caches
43    DEPLOY_BUCKET: rust-lang-gha
44    TOOLSTATE_REPO: https://github.com/pietroalbini/rust-toolstate
45    TOOLSTATE_ISSUES_API_URL: https://api.github.com/repos/pietroalbini/rust-toolstate/issues
46    TOOLSTATE_PUBLISH: 1
47    # AWS_SECRET_ACCESS_KEYs are stored in GitHub's secrets storage, named
48    # AWS_SECRET_ACCESS_KEY_<keyid>. Including the key id in the name allows to
49    # rotate them in a single branch while keeping the old key in another
50    # branch, which wouldn't be possible if the key was named with the kind
51    # (caches, artifacts...).
52    CACHES_AWS_ACCESS_KEY_ID: AKIA46X5W6CZOMUQATD5
53    ARTIFACTS_AWS_ACCESS_KEY_ID: AKIA46X5W6CZH5AYXDVF
54
55  - &base-job
56    env: {}
57
58  - &job-linux-xl
59    os: ubuntu-latest-xl
60    <<: *base-job
61
62  - &job-macos-xl
63    os: macos-latest  # We don't have an XL builder for this
64    <<: *base-job
65
66  - &job-windows-xl
67    os: windows-latest-xl
68    <<: *base-job
69
70  - &step
71    if: success() && !env.SKIP_JOB
72
73  - &step-run
74    <<: *step
75    # While on Linux and macOS builders it just forwards the arguments to the
76    # system bash, this wrapper allows switching from the host's bash.exe to
77    # the one we install along with MSYS2 mid-build on Windows.
78    #
79    # Once the step to install MSYS2 is executed, the CI_OVERRIDE_SHELL
80    # environment variable is set pointing to our MSYS2's bash.exe. From that
81    # moment the host's bash.exe will not be called anymore.
82    #
83    # This is needed because we can't launch our own bash.exe from the host
84    # bash.exe, as that would load two different cygwin1.dll in memory, causing
85    # "cygwin heap mismatch" errors.
86    shell: python src/ci/exec-with-shell.py {0}
87
88  - &base-ci-job
89    timeout-minutes: 600
90    runs-on: "${{ matrix.os }}"
91    env: *shared-ci-variables
92    steps:
93      - name: disable git crlf conversion
94        run: git config --global core.autocrlf false
95        shell: bash
96
97      - name: checkout the source code
98        uses: actions/checkout@v1
99        with:
100          fetch-depth: 2
101
102      - name: configure GitHub Actions to kill the build when outdated
103        uses: rust-lang/simpleinfra/github-actions/cancel-outdated-builds@master
104        with:
105          github_token: "${{ secrets.github_token }}"
106        if: success() && !env.SKIP_JOB && github.ref != 'refs/heads/try'
107        <<: *step
108
109      - name: add extra environment variables
110        run: src/ci/scripts/setup-environment.sh
111        env:
112          # Since it's not possible to merge `${{ matrix.env }}` with the other
113          # variables in `job.<name>.env`, the variables defined in the matrix
114          # are passed to the `setup-environment.sh` script encoded in JSON,
115          # which then uses log commands to actually set them.
116          EXTRA_VARIABLES: ${{ toJson(matrix.env) }}
117        <<: *step-run
118
119      - name: decide whether to skip this job
120        run: src/ci/scripts/should-skip-this.sh
121        <<: *step-run
122
123      - name: collect CPU statistics
124        run: src/ci/scripts/collect-cpu-stats.sh
125        <<: *step-run
126
127      - name: show the current environment
128        run: src/ci/scripts/dump-environment.sh
129        <<: *step-run
130
131      - name: install awscli
132        run: src/ci/scripts/install-awscli.sh
133        <<: *step-run
134
135      - name: install sccache
136        run: src/ci/scripts/install-sccache.sh
137        <<: *step-run
138
139      - name: install clang
140        run: src/ci/scripts/install-clang.sh
141        <<: *step-run
142
143      - name: install WIX
144        run: src/ci/scripts/install-wix.sh
145        <<: *step-run
146
147      - name: install InnoSetup
148        run: src/ci/scripts/install-innosetup.sh
149        <<: *step-run
150
151      - name: ensure the build happens on a partition with enough space
152        run: src/ci/scripts/symlink-build-dir.sh
153        <<: *step-run
154
155      - name: disable git crlf conversion
156        run: src/ci/scripts/disable-git-crlf-conversion.sh
157        <<: *step-run
158
159      - name: install MSYS2
160        run: src/ci/scripts/install-msys2.sh
161        <<: *step-run
162
163      - name: install MSYS2 packages
164        run: src/ci/scripts/install-msys2-packages.sh
165        <<: *step-run
166
167      - name: install MinGW
168        run: src/ci/scripts/install-mingw.sh
169        <<: *step-run
170
171      - name: install ninja
172        run: src/ci/scripts/install-ninja.sh
173        <<: *step-run
174
175      - name: enable ipv6 on Docker
176        run: src/ci/scripts/enable-docker-ipv6.sh
177        <<: *step-run
178
179      # Disable automatic line ending conversion (again). On Windows, when we're
180      # installing dependencies, something switches the git configuration directory or
181      # re-enables autocrlf. We've not tracked down the exact cause -- and there may
182      # be multiple -- but this should ensure submodules are checked out with the
183      # appropriate line endings.
184      - name: disable git crlf conversion
185        run: src/ci/scripts/disable-git-crlf-conversion.sh
186        <<: *step-run
187
188      - name: checkout submodules
189        run: src/ci/scripts/checkout-submodules.sh
190        <<: *step-run
191
192      - name: ensure line endings are correct
193        run: src/ci/scripts/verify-line-endings.sh
194        <<: *step-run
195
196      - name: run the build
197        run: src/ci/scripts/run-build-from-ci.sh
198        env:
199          AWS_ACCESS_KEY_ID: ${{ env.CACHES_AWS_ACCESS_KEY_ID }}
200          AWS_SECRET_ACCESS_KEY: ${{ secrets[format('AWS_SECRET_ACCESS_KEY_{0}', env.CACHES_AWS_ACCESS_KEY_ID)] }}
201          TOOLSTATE_REPO_ACCESS_TOKEN: ${{ secrets.TOOLSTATE_REPO_ACCESS_TOKEN }}
202        <<: *step-run
203
204      - name: upload artifacts to S3
205        run: src/ci/scripts/upload-artifacts.sh
206        env:
207          AWS_ACCESS_KEY_ID: ${{ env.ARTIFACTS_AWS_ACCESS_KEY_ID }}
208          AWS_SECRET_ACCESS_KEY: ${{ secrets[format('AWS_SECRET_ACCESS_KEY_{0}', env.ARTIFACTS_AWS_ACCESS_KEY_ID)] }}
209        # Adding a condition on DEPLOY=1 or DEPLOY_ALT=1 is not needed as all deploy
210        # builders *should* have the AWS credentials available. Still, explicitly
211        # adding the condition is helpful as this way CI will not silently skip
212        # deploying artifacts from a dist builder if the variables are misconfigured,
213        # erroring about invalid credentials instead.
214        if: success() && !env.SKIP_JOB && (github.event_name == 'push' || env.DEPLOY == '1' || env.DEPLOY_ALT == '1')
215        <<: *step-run
216
217  # These snippets are used by the try-success, try-failure, auto-success and auto-failure jobs.
218  # Check out their documentation for more information on why they're needed.
219
220  - &base-outcome-job
221    name: bors build finished
222    runs-on: ubuntu-latest
223
224  - &base-success-job
225    steps:
226      - name: mark the job as a success
227        run: exit 0
228    <<: *base-outcome-job
229
230  - &base-failure-job
231    steps:
232      - name: mark the job as a failure
233        run: exit 1
234    <<: *base-outcome-job
235
236###########################
237#   Builders definition   #
238###########################
239
240name: CI
241on:
242  push:
243    branches:
244      - auto
245      - try
246      - master
247  pull_request:
248    branches:
249      - "**"
250
251jobs:
252  pr:
253    <<: *base-ci-job
254    name: PR
255    env:
256      <<: [*shared-ci-variables, *public-variables]
257    if: github.event_name == 'pull_request'
258    strategy:
259      matrix:
260        name:
261          - mingw-check
262          - x86_64-gnu-llvm-8
263          - x86_64-gnu-tools
264        include:
265          - name: mingw-check
266            <<: *job-linux-xl
267
268          - name: x86_64-gnu-llvm-8
269            <<: *job-linux-xl
270
271          - name: x86_64-gnu-tools
272            env:
273              CI_ONLY_WHEN_SUBMODULES_CHANGED: 1
274            <<: *job-linux-xl
275
276  try:
277    <<: *base-ci-job
278    name: try
279    env:
280      <<: [*shared-ci-variables, *prod-variables]
281    if: github.event_name == 'push' && github.ref == 'refs/heads/try' && github.repository == 'rust-lang-ci/rust'
282    strategy:
283      matrix:
284        name:
285          - dist-x86_64-linux
286          - dist-x86_64-linux-alt
287        include:
288          - name: dist-x86_64-linux
289            <<: *job-linux-xl
290
291          - name: dist-x86_64-linux-alt
292            env:
293              IMAGE: dist-x86_64-linux
294            <<: *job-linux-xl
295
296  auto:
297    <<: *base-ci-job
298    name: auto
299    env:
300      <<: [*shared-ci-variables, *prod-variables]
301    if: github.event_name == 'push' && github.ref == 'refs/heads/auto' && github.repository == 'rust-lang-ci/rust'
302    strategy:
303      matrix:
304        name:
305          - arm-android
306          - armhf-gnu
307          - dist-aarch64-linux
308          - dist-android
309          - dist-arm-linux
310          - dist-armhf-linux
311          - dist-armv7-linux
312          - dist-i586-gnu-i586-i686-musl
313          - dist-i686-freebsd
314          - dist-i686-linux
315          - dist-i686-mingw
316          - dist-i686-msvc
317          - dist-mips-linux
318          - dist-mips64-linux
319          - dist-mips64el-linux
320          - dist-mipsel-linux
321          - dist-powerpc-linux
322          - dist-powerpc64-linux
323          - dist-powerpc64le-linux
324          - dist-s390x-linux
325          - dist-various-1
326          - dist-various-2
327          - dist-x86_64-apple
328          - dist-x86_64-apple-alt
329          - dist-x86_64-freebsd
330          - dist-x86_64-linux
331          - dist-x86_64-linux-alt
332          - dist-x86_64-mingw
333          - dist-x86_64-msvc
334          - dist-x86_64-msvc-alt
335          - dist-x86_64-musl
336          - dist-x86_64-netbsd
337          - i686-gnu
338          - i686-gnu-nopt
339          - i686-mingw-1
340          - i686-mingw-2
341          - i686-msvc-1
342          - i686-msvc-2
343          - mingw-check
344          - test-various
345          - wasm32
346          - x86_64-apple
347          - x86_64-gnu
348          - x86_64-gnu-aux
349          - x86_64-gnu-debug
350          - x86_64-gnu-distcheck
351          - x86_64-gnu-full-bootstrap
352          - x86_64-gnu-llvm-8
353          - x86_64-gnu-nopt
354          - x86_64-gnu-tools
355          - x86_64-mingw-1
356          - x86_64-mingw-2
357          - x86_64-msvc-1
358          - x86_64-msvc-2
359          - x86_64-msvc-aux
360          - x86_64-msvc-cargo
361          - x86_64-msvc-tools
362        include:
363          #############################
364          #   Linux/Docker builders   #
365          #############################
366
367          - name: arm-android
368            <<: *job-linux-xl
369
370          - name: armhf-gnu
371            <<: *job-linux-xl
372
373          - name: dist-aarch64-linux
374            <<: *job-linux-xl
375
376          - name: dist-android
377            <<: *job-linux-xl
378
379          - name: dist-arm-linux
380            <<: *job-linux-xl
381
382          - name: dist-armhf-linux
383            <<: *job-linux-xl
384
385          - name: dist-armv7-linux
386            <<: *job-linux-xl
387
388          - name: dist-i586-gnu-i586-i686-musl
389            <<: *job-linux-xl
390
391          - name: dist-i686-freebsd
392            <<: *job-linux-xl
393
394          - name: dist-i686-linux
395            <<: *job-linux-xl
396
397          - name: dist-mips-linux
398            <<: *job-linux-xl
399
400          - name: dist-mips64-linux
401            <<: *job-linux-xl
402
403          - name: dist-mips64el-linux
404            <<: *job-linux-xl
405
406          - name: dist-mipsel-linux
407            <<: *job-linux-xl
408
409          - name: dist-powerpc-linux
410            <<: *job-linux-xl
411
412          - name: dist-powerpc64-linux
413            <<: *job-linux-xl
414
415          - name: dist-powerpc64le-linux
416            <<: *job-linux-xl
417
418          - name: dist-s390x-linux
419            <<: *job-linux-xl
420
421          - name: dist-various-1
422            <<: *job-linux-xl
423
424          - name: dist-various-2
425            <<: *job-linux-xl
426
427          - name: dist-x86_64-freebsd
428            <<: *job-linux-xl
429
430          - name: dist-x86_64-linux
431            <<: *job-linux-xl
432
433          - name: dist-x86_64-linux-alt
434            env:
435              IMAGE: dist-x86_64-linux
436            <<: *job-linux-xl
437
438          - name: dist-x86_64-musl
439            <<: *job-linux-xl
440
441          - name: dist-x86_64-netbsd
442            <<: *job-linux-xl
443
444          - name: i686-gnu
445            <<: *job-linux-xl
446
447          - name: i686-gnu-nopt
448            <<: *job-linux-xl
449
450          - name: mingw-check
451            <<: *job-linux-xl
452
453          - name: test-various
454            <<: *job-linux-xl
455
456          - name: wasm32
457            <<: *job-linux-xl
458
459          - name: x86_64-gnu
460            <<: *job-linux-xl
461
462          - name: x86_64-gnu-aux
463            <<: *job-linux-xl
464
465          - name: x86_64-gnu-debug
466            <<: *job-linux-xl
467
468          - name: x86_64-gnu-distcheck
469            <<: *job-linux-xl
470
471          - name: x86_64-gnu-full-bootstrap
472            <<: *job-linux-xl
473
474          - name: x86_64-gnu-llvm-8
475            env:
476              RUST_BACKTRACE: 1
477            <<: *job-linux-xl
478
479          - name: x86_64-gnu-nopt
480            <<: *job-linux-xl
481
482          - name: x86_64-gnu-tools
483            env:
484              DEPLOY_TOOLSTATES_JSON: toolstates-linux.json
485            <<: *job-linux-xl
486
487          ####################
488          #  macOS Builders  #
489          ####################
490
491          - name: dist-x86_64-apple
492            env:
493              SCRIPT: ./x.py dist
494              RUST_CONFIGURE_ARGS: --target=aarch64-apple-ios,x86_64-apple-ios --enable-full-tools --enable-sanitizers --enable-profiler --set rust.jemalloc
495              RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
496              MACOSX_DEPLOYMENT_TARGET: 10.7
497              NO_LLVM_ASSERTIONS: 1
498              NO_DEBUG_ASSERTIONS: 1
499              DIST_REQUIRE_ALL_TOOLS: 1
500            <<: *job-macos-xl
501
502          - name: dist-x86_64-apple-alt
503            env:
504              SCRIPT: ./x.py dist
505              RUST_CONFIGURE_ARGS: --enable-extended --enable-profiler --set rust.jemalloc
506              RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
507              MACOSX_DEPLOYMENT_TARGET: 10.7
508              NO_LLVM_ASSERTIONS: 1
509              NO_DEBUG_ASSERTIONS: 1
510            <<: *job-macos-xl
511
512          - name: x86_64-apple
513            env:
514              SCRIPT: ./x.py test
515              RUST_CONFIGURE_ARGS: --build=x86_64-apple-darwin --enable-sanitizers --enable-profiler --set rust.jemalloc
516              RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
517              MACOSX_DEPLOYMENT_TARGET: 10.8
518              MACOSX_STD_DEPLOYMENT_TARGET: 10.7
519              NO_LLVM_ASSERTIONS: 1
520              NO_DEBUG_ASSERTIONS: 1
521            <<: *job-macos-xl
522
523          ######################
524          #  Windows Builders  #
525          ######################
526
527          - name: x86_64-msvc-1
528            env:
529              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --enable-profiler
530              SCRIPT: make ci-subset-1
531              # FIXME(#59637)
532              NO_DEBUG_ASSERTIONS: 1
533              NO_LLVM_ASSERTIONS: 1
534            <<: *job-windows-xl
535
536          - name: x86_64-msvc-2
537            env:
538              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --enable-profiler
539              SCRIPT: make ci-subset-2
540            <<: *job-windows-xl
541
542          - name: i686-msvc-1
543            env:
544              RUST_CONFIGURE_ARGS: --build=i686-pc-windows-msvc
545              SCRIPT: make ci-subset-1
546              # FIXME(#59637)
547              NO_DEBUG_ASSERTIONS: 1
548              NO_LLVM_ASSERTIONS: 1
549            <<: *job-windows-xl
550
551          - name: i686-msvc-2
552            env:
553              RUST_CONFIGURE_ARGS: --build=i686-pc-windows-msvc
554              SCRIPT: make ci-subset-2
555              # FIXME(#59637)
556              NO_DEBUG_ASSERTIONS: 1
557              NO_LLVM_ASSERTIONS: 1
558            <<: *job-windows-xl
559
560          - name: x86_64-msvc-aux
561            env:
562              RUST_CHECK_TARGET: check-aux EXCLUDE_CARGO=1
563              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc
564            <<: *job-windows-xl
565
566          - name: x86_64-msvc-cargo
567            env:
568              SCRIPT: python x.py test src/tools/cargotest src/tools/cargo
569              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc
570              VCVARS_BAT: vcvars64.bat
571              # FIXME(#59637)
572              NO_DEBUG_ASSERTIONS: 1
573              NO_LLVM_ASSERTIONS: 1
574            <<: *job-windows-xl
575
576          - name: x86_64-msvc-tools
577            env:
578              SCRIPT: src/ci/docker/x86_64-gnu-tools/checktools.sh x.py /tmp/toolstate/toolstates.json windows
579              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --save-toolstates=/tmp/toolstate/toolstates.json
580            <<: *job-windows-xl
581
582          # 32/64-bit MinGW builds.
583          #
584          # We are using MinGW with posix threads since LLVM does not compile with
585          # the win32 threads version due to missing support for C++'s std::thread.
586          #
587          # Instead of relying on the MinGW version installed on appveryor we download
588          # and install one ourselves so we won't be surprised by changes to appveyor's
589          # build image.
590          #
591          # Finally, note that the downloads below are all in the `rust-lang-ci` S3
592          # bucket, but they cleraly didn't originate there! The downloads originally
593          # came from the mingw-w64 SourceForge download site. Unfortunately
594          # SourceForge is notoriously flaky, so we mirror it on our own infrastructure.
595
596          - name: i686-mingw-1
597            env:
598              RUST_CONFIGURE_ARGS: --build=i686-pc-windows-gnu
599              SCRIPT: make ci-mingw-subset-1
600              CUSTOM_MINGW: 1
601              # FIXME(#59637)
602              NO_DEBUG_ASSERTIONS: 1
603              NO_LLVM_ASSERTIONS: 1
604            <<: *job-windows-xl
605
606          - name: i686-mingw-2
607            env:
608              RUST_CONFIGURE_ARGS: --build=i686-pc-windows-gnu
609              SCRIPT: make ci-mingw-subset-2
610              CUSTOM_MINGW: 1
611            <<: *job-windows-xl
612
613          - name: x86_64-mingw-1
614            env:
615              SCRIPT: make ci-mingw-subset-1
616              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-gnu
617              CUSTOM_MINGW: 1
618              # FIXME(#59637)
619              NO_DEBUG_ASSERTIONS: 1
620              NO_LLVM_ASSERTIONS: 1
621            <<: *job-windows-xl
622
623          - name: x86_64-mingw-2
624            env:
625              SCRIPT: make ci-mingw-subset-2
626              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-gnu
627              CUSTOM_MINGW: 1
628            <<: *job-windows-xl
629
630          - name: dist-x86_64-msvc
631            env:
632              RUST_CONFIGURE_ARGS: >-
633                --build=x86_64-pc-windows-msvc
634                --target=x86_64-pc-windows-msvc,aarch64-pc-windows-msvc
635                --enable-full-tools
636                --enable-profiler
637              SCRIPT: python x.py dist
638              DIST_REQUIRE_ALL_TOOLS: 1
639            <<: *job-windows-xl
640
641          - name: dist-i686-msvc
642            env:
643              RUST_CONFIGURE_ARGS: >-
644                --build=i686-pc-windows-msvc
645                --target=i586-pc-windows-msvc
646                --enable-full-tools
647                --enable-profiler
648              SCRIPT: python x.py dist
649              DIST_REQUIRE_ALL_TOOLS: 1
650            <<: *job-windows-xl
651
652          - name: dist-i686-mingw
653            env:
654              RUST_CONFIGURE_ARGS: --build=i686-pc-windows-gnu --enable-full-tools --enable-profiler
655              SCRIPT: python x.py dist
656              CUSTOM_MINGW: 1
657              DIST_REQUIRE_ALL_TOOLS: 1
658            <<: *job-windows-xl
659
660          - name: dist-x86_64-mingw
661            env:
662              SCRIPT: python x.py dist
663              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-gnu --enable-full-tools --enable-profiler
664              CUSTOM_MINGW: 1
665              DIST_REQUIRE_ALL_TOOLS: 1
666            <<: *job-windows-xl
667
668          - name: dist-x86_64-msvc-alt
669            env:
670              RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --enable-extended --enable-profiler
671              SCRIPT: python x.py dist
672            <<: *job-windows-xl
673
674  master:
675    name: master
676    runs-on: ubuntu-latest
677    env:
678      <<: [*prod-variables]
679    if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository == 'rust-lang-ci/rust'
680    steps:
681      - name: checkout the source code
682        uses: actions/checkout@v1
683        with:
684          fetch-depth: 2
685
686      - name: publish toolstate
687        run: src/ci/publish_toolstate.sh
688        env:
689          TOOLSTATE_REPO_ACCESS_TOKEN: ${{ secrets.TOOLSTATE_REPO_ACCESS_TOKEN }}
690        <<: *step-run
691
692  # These jobs don't actually test anything, but they're used to tell bors the
693  # build completed, as there is no practical way to detect when a workflow is
694  # successful listening to webhooks only.
695  try-success:
696    needs: [try]
697    if: "success() && github.event_name == 'push' && github.ref == 'refs/heads/try' && github.repository == 'rust-lang-ci/rust'"
698    <<: *base-success-job
699  try-failure:
700    needs: [try]
701    if: "!success() && github.event_name == 'push' && github.ref == 'refs/heads/try' && github.repository == 'rust-lang-ci/rust'"
702    <<: *base-failure-job
703  auto-success:
704    needs: [auto]
705    if: "success() && github.event_name == 'push' && github.ref == 'refs/heads/auto' && github.repository == 'rust-lang-ci/rust'"
706    <<: *base-success-job
707  auto-failure:
708    needs: [auto]
709    if: "!success() && github.event_name == 'push' && github.ref == 'refs/heads/auto' && github.repository == 'rust-lang-ci/rust'"
710    <<: *base-failure-job