diff options
author | Tim Smith <tsmith84@gmail.com> | 2021-09-13 20:53:09 -0700 |
---|---|---|
committer | Tim Smith <tsmith84@gmail.com> | 2021-09-15 06:58:39 -0700 |
commit | a62eda8722bd66a165e14400f6d25ce3b0880881 (patch) | |
tree | 2e6d222c8a7a03f4dd214d24a571b6dfa6f2fee4 /.expeditor | |
parent | 0d48076e5eb1acc0ccd6ba07e7c287840b35a637 (diff) | |
download | chef-a62eda8722bd66a165e14400f6d25ce3b0880881.tar.gz |
Automate release announcements
Make the machine do my job.
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to '.expeditor')
-rwxr-xr-x | .expeditor/announce-release.sh | 45 | ||||
-rw-r--r-- | .expeditor/config.yml | 8 | ||||
-rwxr-xr-x | .expeditor/publish-release-notes.sh | 32 |
3 files changed, 80 insertions, 5 deletions
diff --git a/.expeditor/announce-release.sh b/.expeditor/announce-release.sh new file mode 100755 index 0000000000..58d1b1e463 --- /dev/null +++ b/.expeditor/announce-release.sh @@ -0,0 +1,45 @@ +#!/bin/bash + +set -exou pipefail + +# Download the release-notes for our specific build +curl -o release-notes.md "https://packages.chef.io/release-notes/${EXPEDITOR_PRODUCT_KEY}/${EXPEDITOR_VERSION}.md" + +topic_title="Chef Infra Client $EXPEDITOR_VERSION Released!" +topic_body=$(cat <<EOH +We are delighted to announce the availability of version $EXPEDITOR_VERSION of Chef Infra Client. + +$(cat release-notes.md) + +--- +## Get the Build + +As always, you can download binaries directly from [downloads.chef.io](https://downloads.chef.io/products/infra?v=${EXPEDITOR_VERSION}) or by using the `mixlib-install` command-line utility: + +``` +$ mixlib-install download chef -v ${EXPEDITOR_VERSION} +``` + +Alternatively, you can install Chef Infra Client using one of the following command options: + +``` +# In Shell +$ curl https://omnitruck.chef.io/install.sh | sudo bash -s -- -P chef -v ${EXPEDITOR_VERSION} +# In Windows Powershell +. { iwr -useb https://omnitruck.chef.io/install.ps1 } | iex; install -project chef -version ${EXPEDITOR_VERSION} +``` +If you want to give this version a spin in Test Kitchen, create or add the following to your `kitchen.yml` file: + +``` +provisioner: + product_name: chef + product_version: ${EXPEDITOR_VERSION} +``` +EOH +) + +# Use Expeditor's built in Bash helper to post our message: https://git.io/JvxPm +post_discourse_release_announcement "$topic_title" "$topic_body" + +# Cleanup +rm release-notes.md diff --git a/.expeditor/config.yml b/.expeditor/config.yml index f8c6e9e778..067f7394ac 100644 --- a/.expeditor/config.yml +++ b/.expeditor/config.yml @@ -51,7 +51,7 @@ github: major_bump_labels: - "Expeditor: Bump Version Major" -# Which Github branches to build Omnibus releases from, and what versions +# Which GitHub branches to build Omnibus releases from, and what versions # (as determined by the value in the VERSION file) those branches are responsible # for building. release_branches: @@ -59,10 +59,6 @@ release_branches: version_constraint: 17* - chef-16: version_constraint: 16* - - chef-15: - version_constraint: 15* - - chef-14: - version_constraint: 14* changelog: rollup_header: Changes not yet released to stable @@ -80,6 +76,8 @@ subscriptions: - built_in:rollover_changelog - bash:.expeditor/update_dockerfile.sh - bash:.expeditor/promote-docker-images.sh + - bash:.expeditor/publish-release-notes.sh + - bash:.expeditor/announce-release.sh - built_in:publish_rubygems - built_in:promote_habitat_packages - built_in:notify_chefio_slack_channels diff --git a/.expeditor/publish-release-notes.sh b/.expeditor/publish-release-notes.sh new file mode 100755 index 0000000000..fc89315bb5 --- /dev/null +++ b/.expeditor/publish-release-notes.sh @@ -0,0 +1,32 @@ +#!/bin/bash + +set -eou pipefail + +git clone https://x-access-token:${GITHUB_TOKEN}@github.com/chef/chef.wiki.git + +pushd ./chef.wiki + # Publish release notes to S3 + aws s3 cp Pending-Release-Notes.md "s3://chef-automate-artifacts/release-notes/${EXPEDITOR_PRODUCT_KEY}/${EXPEDITOR_VERSION}.md" --acl public-read --content-type "text/plain" --profile chef-cd + aws s3 cp Pending-Release-Notes.md "s3://chef-automate-artifacts/${EXPEDITOR_CHANNEL}/latest/${EXPEDITOR_PRODUCT_KEY}/release-notes.md" --acl public-read --content-type "text/plain" --profile chef-cd + + # Reset "Stable Release Notes" wiki page + cat >./Pending-Release-Notes.md <<EOH +## Compliance Phase Improvements + +## New Resources + +## Resource Updates + +## Packaging + +## Security + +EOH + + # Push changes back up to GitHub + git add . + git commit -m "Release Notes for promoted build $EXPEDITOR_VERSION" + git push origin main +popd + +rm -rf chef.wiki |