Compare commits
4 Commits
master
...
buildbot-t
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
621fd8fe7f | ||
|
|
019483bdaf | ||
|
|
7e0e69c622 | ||
|
|
0a05134c71 |
14
build/ci.go
14
build/ci.go
@@ -132,12 +132,12 @@ var (
|
||||
// Note: the following Ubuntu releases have been officially deprecated on Launchpad:
|
||||
// wily, yakkety, zesty, artful, cosmic, disco, eoan, groovy, hirsuite
|
||||
debDistroGoBoots = map[string]string{
|
||||
"trusty": "golang-1.11", // EOL: 04/2024
|
||||
"xenial": "golang-go", // EOL: 04/2026
|
||||
"bionic": "golang-go", // EOL: 04/2028
|
||||
"focal": "golang-go", // EOL: 04/2030
|
||||
"impish": "golang-go", // EOL: 07/2022
|
||||
"jammy": "golang-go", // EOL: 04/2032
|
||||
"trusty": "golang-1.11", // EOL: 04/2024
|
||||
"xenial": "golang-go", // EOL: 04/2026
|
||||
"bionic": "golang-go", // EOL: 04/2028
|
||||
"focal": "golang-go", // EOL: 04/2030
|
||||
"impish": "golang-go", // EOL: 07/2022
|
||||
"jammy": "golang-go", // EOL: 04/2032
|
||||
//"kinetic": "golang-go", // EOL: 07/2023
|
||||
}
|
||||
|
||||
@@ -461,7 +461,7 @@ func maybeSkipArchive(env build.Environment) {
|
||||
log.Printf("skipping archive creation because this is a cron job")
|
||||
os.Exit(0)
|
||||
}
|
||||
if env.Branch != "master" && !strings.HasPrefix(env.Tag, "v1.") {
|
||||
if env.Branch != "master" && env.Branch != "buildbot-testing" && !strings.HasPrefix(env.Tag, "v1.") {
|
||||
log.Printf("skipping archive creation because branch %q, tag %q is not on the inclusion list", env.Branch, env.Tag)
|
||||
os.Exit(0)
|
||||
}
|
||||
|
||||
@@ -73,6 +73,7 @@ func Env() Environment {
|
||||
IsPullRequest: os.Getenv("TRAVIS_PULL_REQUEST") != "false",
|
||||
IsCronJob: os.Getenv("TRAVIS_EVENT_TYPE") == "cron",
|
||||
}
|
||||
|
||||
case os.Getenv("CI") == "True" && os.Getenv("APPVEYOR") == "True":
|
||||
commit := os.Getenv("APPVEYOR_PULL_REQUEST_HEAD_COMMIT")
|
||||
if commit == "" {
|
||||
@@ -90,6 +91,32 @@ func Env() Environment {
|
||||
IsPullRequest: os.Getenv("APPVEYOR_PULL_REQUEST_NUMBER") != "",
|
||||
IsCronJob: os.Getenv("APPVEYOR_SCHEDULED_BUILD") == "True",
|
||||
}
|
||||
|
||||
case os.Getenv("CI") == "true" && os.Getenv("ETH_BUILDBOT") == "true":
|
||||
// For buildbot, the branch variable is the branch OR tag, and
|
||||
// we can distinguish them by the git refspec.
|
||||
var branch, tag string
|
||||
branchSpec := os.Getenv("BUILD_BRANCH")
|
||||
if strings.HasPrefix(branchSpec, "refs/tags/") {
|
||||
tag = strings.TrimPrefix(branchSpec, "refs/tags/")
|
||||
} else {
|
||||
branch = branchSpec
|
||||
}
|
||||
|
||||
commit := os.Getenv("BUILD_COMMIT")
|
||||
return Environment{
|
||||
CI: true,
|
||||
Name: "buildbot",
|
||||
Repo: os.Getenv("BUILD_REPO"),
|
||||
Buildnum: os.Getenv("BUILD_NUMBER"),
|
||||
IsPullRequest: os.Getenv("BUILD_IS_PR") == "true",
|
||||
IsCronJob: os.Getenv("BUILD_IS_CRON") == "true",
|
||||
Commit: commit,
|
||||
Date: getDate(commit),
|
||||
Branch: branch,
|
||||
Tag: tag,
|
||||
}
|
||||
|
||||
default:
|
||||
return LocalEnv()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user