diff options
author | Jesse Prieur <84023513+jesseprieur@users.noreply.github.com> | 2023-02-14 16:09:30 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-14 11:09:30 -0500 |
commit | 665274de02c04ce5e8ae96033c49e2862ed05e5b (patch) | |
tree | 5cb96af8287078dfc4d440a403a3a0b362f5f719 | |
parent | 2519d5282eeb2d10a92743ec5c37414e7b6f3bf9 (diff) | |
download | chef-665274de02c04ce5e8ae96033c49e2862ed05e5b.tar.gz |
Add rest of windows platforms to be tested on; Fixing syntax issue in build-test-omnibus (#13565)
* Adding rest of windows platforms to test on
* Changing windows platforms to only test 2019 on a default agent in chef-oss; otherwise test everything on the omnibus agents
* Adding key to test steps in pipeline
* Only set secrets on non-test steps
* remove caching plugin
* remove windows 8 from chef-18 pipeline
Signed-off-by: Evan Ahlberg <evanahlberg@gmail.com>
---------
Signed-off-by: Jesse Prieur <jesse.prieur@gmail.com>
Signed-off-by: Evan Ahlberg <evanahlberg@gmail.com>
Co-authored-by: Evan Ahlberg <evanahlberg@gmail.com>
-rwxr-xr-x | .buildkite/build-test-omnibus.sh | 24 | ||||
-rw-r--r-- | .buildkite/hooks/pre-command | 2 | ||||
-rwxr-xr-x | .buildkite/verify.pipeline.sh | 18 |
3 files changed, 28 insertions, 16 deletions
diff --git a/.buildkite/build-test-omnibus.sh b/.buildkite/build-test-omnibus.sh index ddf4c9533f..ef77287e5b 100755 --- a/.buildkite/build-test-omnibus.sh +++ b/.buildkite/build-test-omnibus.sh @@ -11,6 +11,12 @@ FILTER="${OMNIBUS_FILTER:=*}" # array of all container platforms in the format test-platform:build-platform container_platforms=("amazon-2:centos-7" "centos-6:centos-6" "centos-7:centos-7" "centos-8:centos-8" "rhel-9:rhel-9" "debian-9:debian-9" "debian-10:debian-9" "debian-11:debian-9" "ubuntu-1604:ubuntu-1604" "ubuntu-1804:ubuntu-1604" "ubuntu-2004:ubuntu-1604" "ubuntu-2204:ubuntu-1604" "sles-15:sles-15" "windows-2019:windows-2019") +# add rest of windows platforms to tests, if not on chef-oss org +if [ $BUILDKITE_ORGANIZATION_SLUG != "chef-oss" ] +then + container_platforms=( "${container_platforms[@]}" "windows-2012:windows-2019" "windows-2012r2:windows-2019" "windows-2016:windows-2019" "windows-2022:windows-2019" "windows-10:windows-2019" "windows-11:windows-2019" ) +fi + # array of all esoteric platforms in the format test-platform:build-platform esoteric_platforms=("aix-7.1-powerpc:aix-7.1-powerpc" "aix-7.2-powerpc:aix-7.1-powerpc" "aix-7.3-powerpc:aix-7.1-powerpc" "el-7-ppc64:el-7-ppc64" "el-7-ppc64le:el-7-ppc64le" "el-7-s390x:el-7-s390x" "el-8-s390x:el-7-s390x" "freebsd-12-amd64:freebsd-12-amd64" "freebsd-13-amd64:freebsd-12-amd64" "mac_os_x-10.15-x86_64:mac_os_x-10.15-x86_64" "mac_os_x-11-x86_64:mac_os_x-10.15-x86_64" "mac_os_x-12-x86_64:mac_os_x-10.15-x86_64" "mac_os_x-11-arm64:mac_os_x-11-arm64" "mac_os_x-12-arm64:mac_os_x-11-arm64" "solaris2-5.11-i386:solaris2-5.11-i386" "solaris2-5.11-sparc:solaris2-5.11-sparc" "sles-12-s390x:sles-12-s390x" "sles-15-s390x:sles-12-s390x") @@ -190,7 +196,7 @@ then echo " label: \":artifactory: Create Build Record\"" echo " plugins:" echo " - chef/omnibus#v0.2.83:" - echo " create-build-record: chef" + echo " create-build-record: chef" fi echo "- wait: ~" @@ -204,6 +210,7 @@ then echo "- env:" echo " OMNIBUS_BUILDER_KEY: build-${platform#*:}" echo " label: \":mag::docker: ${platform%:*}\"" + echo " key: test-${platform%:*}" echo " retry:" echo " automatic:" echo " limit: 1" @@ -220,14 +227,19 @@ then echo " timeout_in_minutes: 60" else echo "- env:" - echo " OMNIBUS_BUILDER_KEY: build-windows-2019" - echo " key: test-windows-2019" - echo ' label: ":mag::windows: windows-2019"' + echo " OMNIBUS_BUILDER_KEY: build-${platform#*:}" + echo " label: \":mag::windows: ${platform%:*}\"" + echo " key: test-${platform%:*}" echo " retry:" echo " automatic:" echo " limit: 1" echo " agents:" - echo " queue: default-windows-2019-privileged" + if [ $BUILDKITE_ORGANIZATION_SLUG == "chef-oss" ] + then + echo " queue: default-${platform%:*}-privileged" + else + echo " queue: omnibus-${platform%:*}-x86_64" + fi echo " commands:" echo " - ./.expeditor/scripts/download_built_omnibus_pkgs.ps1" echo " - ./omnibus/omnibus-test.ps1" @@ -293,5 +305,5 @@ then echo " label: \":artifactory: Promote to Current\"" echo " plugins:" echo " - chef/omnibus#v0.2.83:" - echo " promote: chef" + echo " promote: chef" fi
\ No newline at end of file diff --git a/.buildkite/hooks/pre-command b/.buildkite/hooks/pre-command index f4c1f76d42..26c80c7f27 100644 --- a/.buildkite/hooks/pre-command +++ b/.buildkite/hooks/pre-command @@ -59,7 +59,7 @@ if [[ "$BUILDKITE_BRANCH" != "main" ]]; then fi # Only if on chef-canary or chef org -if [[ $BUILDKITE_ORGANIZATION_SLUG != "chef-oss" ]]; then +if [[ ! "$BUILDKITE_STEP_KEY" =~ ^test.* ]] && [[ $BUILDKITE_ORGANIZATION_SLUG != "chef-oss" ]]; then export VAULT_ADDR="https://vault.ps.chef.co" export VAULT_TOKEN=$(vault login -method=aws -path=aws/private-cd -token-only header_value=vault.ps.chef.co role=ci) diff --git a/.buildkite/verify.pipeline.sh b/.buildkite/verify.pipeline.sh index c675ab42f6..9e36d2cb6d 100755 --- a/.buildkite/verify.pipeline.sh +++ b/.buildkite/verify.pipeline.sh @@ -96,10 +96,10 @@ for gem in ${external_gems[@]}; do echo " - CHEF_FS=true" fi echo " propagate-environment: true" - echo " - chef/cache#v1.5.0:" - echo " s3_bucket: core-buildkite-cache-chef-oss-prod" - echo " cached_folders:" - echo " - vendor" + # echo " - chef/cache#v1.5.0:" + # echo " s3_bucket: core-buildkite-cache-chef-oss-prod" + # echo " cached_folders:" + # echo " - vendor" echo " timeout_in_minutes: 60" echo " commands:" echo " - .expeditor/scripts/bk_container_prep.sh" @@ -153,11 +153,11 @@ for plan in ${habitat_plans[@]}; do else echo " queue: single-use-privileged" fi - echo " plugins:" - echo " - chef/cache#v1.5.0:" - echo " s3_bucket: core-buildkite-cache-chef-oss-prod" - echo " cached_folders:" - echo " - vendor" + # echo " plugins:" + # echo " - chef/cache#v1.5.0:" + # echo " s3_bucket: core-buildkite-cache-chef-oss-prod" + # echo " cached_folders:" + # echo " - vendor" echo " timeout_in_minutes: 60" echo " commands:" if [ $plan == "windows" ] |