Skip to content

Commit c6af14a

Browse files
committed
adapt pipeline for prod releases
Signed-off-by: Christian Richter <c.richter@opencloud.eu> # Conflicts: # .woodpecker.star
1 parent fa32dff commit c6af14a

1 file changed

Lines changed: 20 additions & 2 deletions

File tree

.woodpecker.star

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1821,13 +1821,13 @@ def dockerReleases(ctx):
18211821

18221822
def checkVersionPlaceholder():
18231823
return [{
1824-
"name": "check-version-placeholder",
1824+
"name": "check-version-placeholder-next",
18251825
"steps": [
18261826
{
18271827
"name": "check-version-placeholder",
18281828
"image": OC_CI_ALPINE,
18291829
"commands": [
1830-
"grep -r -e '%%NEXT%%' %s/services %s/pkg > next_version.txt || true" % (
1830+
"grep -r -e '%%NEXT%%' %s/services %s/pkg > next_version.txt" % (
18311831
dirs["base"],
18321832
dirs["base"],
18331833
),
@@ -1838,6 +1838,24 @@ def checkVersionPlaceholder():
18381838
"when": [
18391839
event["pull_request"],
18401840
],
1841+
"name": "check-version-placeholder-next-production-release",
1842+
"steps": [
1843+
{
1844+
"name": "check-version-placeholder",
1845+
"image": OC_CI_ALPINE,
1846+
"commands": [
1847+
"grep -r -e '%%NEXT_PRODUCTION_VERSION%%' %s/services %s/pkg > next_production_version.txt" % (
1848+
dirs["base"],
1849+
dirs["base"],
1850+
),
1851+
'if [ -s next_production_version.txt ]; then echo "replace version placeholders"; cat next_production_version.txt; exit 1; fi',
1852+
],
1853+
},
1854+
],
1855+
"when": [
1856+
event["pull_request"],
1857+
evaluate['CI_COMMIT_PULL_REQUEST_LABELS contains "production_release"']
1858+
],
18411859
}]
18421860

18431861
def dockerRelease(ctx, repo, build_type):

0 commit comments

Comments
 (0)