New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build: script to make custom builds #54661
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
One small question, do you think that it would be useful to have periodic echo
s that explain what the script is doing, or would that be too verbose? I'm thinking of something like "creating tag $TAG for sha $SHA", and "pushing tag $TAG". I could image that this could be useful in case somehow something goes wrong with the script you can see what it was trying to do. My reservation here is that it might be too verbose.
scripts/tag-custom-build.sh
Outdated
|
||
echo | ||
echo "Tag name: $TAG" | ||
echo "Build ID: $ID" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a link (that is relatively stable and won't change too much) that we could echo here to point the user towards Make And Publish build? Maybe we could also add a message that they should be able to find the tag name there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Done.
I'm not sure we need to checkout in the local workdir at all (and mess with submodules, dirty checkouts, etc) do we? Like, can't this all just be |
Before: We had the old build process and a not-so-great way to make custom builds. Why: We have a new build process that includes a facility for making custom builds and we want it to be very easy to use. Now: This script automates much of the process of making a custom build and makes it very easy to create one on short notice. Comments in the script describe how to use it and where to go for getting the binaries and docker image. This commit also changes the teamcity-make-and-publish-build.sh script to delete the temporary custombuild- tag and to be consistent in naming the Build ID. Release note: None
0a143b4
to
a88763c
Compare
Yes. You're right. Updated. Thanks!
I was ready to add the messages before removing the checking out of the tag. Now there's so little happening and the commands that do run should say why they fail if they fail, that it doesn't seem like it's needed. |
bors r+ TFTR! |
Build succeeded: |
Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR cockroachdb#54661 causing master to fail builds in Make and Publish Build. Release note: None
Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR cockroachdb#54661 causing master to fail builds in Make and Publish Build. Release note: None
55505: build: fix builds using grep to match a string. r=pbardea a=jlinder Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR #54661 causing master to fail builds in Make and Publish Build. Release note: None 55516: roachtest: temporarily omit testing setting in sqlsmith r=yuzefovich a=yuzefovich Recently introduced `testing_vectorize_inject_panics` testing session variable is only supported on master branch, so we need to gate its usage based on the version. However, 21.1 version hasn't been minted yet, so we temporarily disable the setting's usage. Fixes: #55482. Release note: None Co-authored-by: James H. Linder <jamesl@cockroachlabs.com> Co-authored-by: Yahor Yuzefovich <yahor@cockroachlabs.com>
Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR cockroachdb#54661 causing master to fail builds in Make and Publish Build. Release note: None
Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR cockroachdb#54661 causing master to fail builds in Make and Publish Build. Release note: None
Before: `grep -Eo` was used in a couple places in release scripts where it might not find the string being searched for, the non-zero return code wasn't handled and the script should have continued executing. Why: The release scripts were erroring out when they should have continued executing. Now: The non-zero return code is handled by adding a `|| echo""` to the commands. This was discovered by PR cockroachdb#54661 causing master to fail builds in Make and Publish Build. Release note: None
Before: We had the old build process and a not-so-great way to make
custom builds.
Why: We have a new build process that includes a facility for making
custom builds and we want it to be very easy to use.
Now:
This script automates much of the process of making a custom build
and makes it very easy to create one on short notice. Comments in the
script describe how to use it and where to go for getting the binaries
and docker image.
This commit also changes the teamcity-make-and-publish-build.sh script
to delete the temporary custombuild- tag and to be consistent in naming
the Build ID.
Part of #45487
Release note: None