Skip to content

Commit ec30bcc

Browse files
committed
ci: add logic to do multiple docker releases for non-patch production-releases
1 parent 61a591b commit ec30bcc

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

.woodpecker.star

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,8 @@ config = {
388388
"production": {
389389
# NOTE: need to be updated if new production releases are determined
390390
"tags": ["2.0", "4.0"],
391+
# NOTE: need to be set to true if patch releases are made from stable-X-branches
392+
"skip_rolling": "false",
391393
"repo": docker_repo_slug,
392394
"build_type": "production",
393395
},
@@ -1617,13 +1619,19 @@ def dockerReleases(ctx):
16171619

16181620
# iterate over production tags to see if this is a production release
16191621
is_production = False
1622+
skip_rolling = False
16201623
for prod_tag in config["dockerReleases"]["production"]["tags"]:
16211624
if tag.startswith(prod_tag):
16221625
is_production = True
1626+
skip_rolling = config["dockerReleases"]["production"]["skip_rolling"]
16231627
break
16241628

16251629
if is_production:
16261630
docker_releases.append("production")
1631+
# a new production realease is also a rolling release
1632+
# unless skip_rolling is set in the config, i.e. for patch-releases on stable-branch
1633+
if not skip_rolling:
1634+
docker_releases.append("rolling")
16271635

16281636
else:
16291637
docker_releases.append("rolling")

0 commit comments

Comments
 (0)