@@ -28,11 +28,42 @@ steps:
28
28
commands :
29
29
- yarn test
30
30
31
- build_step :
32
- type : build
33
- dockerfile : Dockerfile
34
- image-name : codefresh/cli
35
- tag : ${{CF_BRANCH_TAG_NORMALIZED}}
31
+ extract_version :
32
+ title : " Exporting package.json version"
33
+ image : codefresh/build-cli
34
+ commands :
35
+ - ' export PACKAGE_VERSION=$(jq -r ".version" package.json)'
36
+ - " echo Current version: $PACKAGE_VERSION"
37
+ - " cf_export PACKAGE_VERSION"
38
+
39
+ build_images :
40
+ type : parallel
41
+ steps :
42
+
43
+ build_step :
44
+ type : build
45
+ dockerfile : Dockerfile
46
+ image-name : codefresh/cli
47
+ tag : ${{CF_BRANCH_TAG_NORMALIZED}}
48
+
49
+ run_arm_build :
50
+ type : codefresh-run
51
+ arguments :
52
+ PIPELINE_ID : ' codefresh-io/cli/build-arm'
53
+ TRIGGER_ID : codefresh-io/cli
54
+ BRANCH : ${{CF_BRANCH}}
55
+ DETACH : false
56
+ VARIABLE :
57
+ - CF_REPO_OWNER=${{CF_REPO_OWNER}}
58
+ - CF_REPO_NAME=${{CF_REPO_NAME}}
59
+ - CF_REVISION=${{CF_REVISION}}
60
+ - CF_BRANCH=${{CF_BRANCH}}
61
+ - CF_SHORT_REVISION=${{CF_SHORT_REVISION}}
62
+ - GIT_CONTEXT=cf_github
63
+ - IMAGE_NAME=codefresh/cli
64
+ - WORKDIR=${{CF_VOLUME_PATH}}/${{CF_REPO_NAME}}
65
+ - ARM_TAG_POSTFIX="${{ARM_TAG_POSTFIX}}"
66
+ - PACKAGE_VERSION=${{PACKAGE_VERSION}}
36
67
37
68
push_step :
38
69
type : push
@@ -41,19 +72,49 @@ steps:
41
72
scale :
42
73
push_to_dockerhub :
43
74
registry : dockerhub
44
- title : " push to dockerhub"
75
+ title : " push to dockerhub"
45
76
push_to_gcr :
46
- title : " push to gcr"
77
+ title : " push to gcr"
78
+ push_to_quay :
79
+ registry : cf-quay
80
+ title : " push to quay.io"
81
+
82
+ create_manifest_list :
83
+ type : " codefresh-inc/multiarch-manifester"
84
+ arguments :
85
+ image_name : codefresh/cli
86
+ arch_tag_postfixes :
87
+ arm64 : " ${{ARM_TAG_POSTFIX}}"
88
+ registries :
89
+ - name : ' quay.io'
90
+ username : ' ${{QUAY_USERNAME}}'
91
+ password : ' ${{QUAY_PASSWORD}}'
92
+ - name : ' docker.io'
93
+ username : ' ${{DOCKERHUB_USERNAME}}'
94
+ password : ' ${{DOCKERHUB_PASSWORD}}'
95
+ - name : ' gcr.io'
96
+ path_prefix : codefresh-inc
97
+ username : ' ${{GCR_CODEFRESH_INC_USERNAME}}'
98
+ password : ' ${{GCR_CODEFRESH_INC_PASSWORD}}'
99
+ scale :
100
+ dev_branches_tags :
101
+ when :
102
+ branch :
103
+ ignore : [ master ]
104
+ arguments :
105
+ tags :
106
+ - ${{CF_SHORT_REVISION}}
47
107
48
108
execute_release_pipeline :
49
109
title : " Execute release pipeline in case version was changed"
50
110
fail_fast : false
51
- image : codefresh/cli
52
- commands :
53
- - ' apk update && apk add jq'
54
- - ' export PACKAGE_VERSION=$(jq -r ".version" package.json)'
55
- - " echo Current version: $PACKAGE_VERSION"
56
- - " git tag $PACKAGE_VERSION && echo Running release pipeline && codefresh run 5a4c94d282ed4d00012b54e8 -b=master --detach"
111
+ type : codefresh-run
112
+ arguments :
113
+ PIPELINE_ID : ' codefresh-io/cli/release'
114
+ DETACH : true
115
+ BRANCH : master
116
+ VARIABLE :
117
+ - PACKAGE_VERSION=${{PACKAGE_VERSION}}
57
118
when :
58
119
branch :
59
120
only : [ master ]
0 commit comments