mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-30 15:05:27 +00:00
hack: ensure go version is not specified for master in publishing rules
The go version for all master branches is defined in `default-go-version` locally. Note that this validation isn't added to publishing-bot directly because we still want to give users of the publishing-bot the ability to specify specific go versions for the master branch if they need, but we want to explicitly disallow this for kubernetes repos.
This commit is contained in:
parent
ef90e6cbb3
commit
1dffb87037
@ -86,6 +86,11 @@ def main():
|
||||
if branch["source"]["branch"] != "master":
|
||||
raise Exception("cannot find master source branch for destination %s" % rule["destination"])
|
||||
|
||||
# we specify the go version for all master branches through `default-go-version`
|
||||
# so ensure we don't specify explicit go version for master branch in rules
|
||||
if "go" in branch:
|
||||
raise Exception("go version must not be specified for master branch for destination %s" % rule["destination"])
|
||||
|
||||
print("processing : %s" % rule["destination"])
|
||||
if rule["destination"] not in gomod_dependencies:
|
||||
raise Exception("missing go.mod for %s" % rule["destination"])
|
||||
|
Loading…
Reference in New Issue
Block a user