@@ -42,37 +42,60 @@ jobs:
4242
4343 echo "VERSION:$version"
4444 tag="v${version}"
45- echo "::set-output name= version:: $version"
46- echo "::set-output name= tag:: $tag"
45+ echo "version= $version" >> $GITHUB_OUTPUT
46+ echo "tag= $tag" >> $GITHUB_OUTPUT
4747
4848 - name : Check out code into the Go module directory
49- uses : actions/checkout@v3.0 .0
49+ uses : actions/checkout@v3.1 .0
5050 with :
51+ submodules : true
5152 fetch-depth : 0 # needs for tags
5253
5354 - name : Create configuration package
5455 run : |
5556 set -x
5657 tar czvf atlas-operator-all-in-one-${{ steps.tag.outputs.version }}.tar.gz -C deploy all-in-one.yaml
5758
58- - name : Push Atlas Operator to Registry
59- uses : docker/build-push- action@v1
59+ - name : Login to docker registry
60+ uses : docker/login- action@v2
6061 with :
62+ registry : ${{ env.DOCKER_REGISTRY }}
6163 username : ${{ secrets.DOCKER_USERNAME }}
6264 password : ${{ secrets.DOCKER_PASSWORD }}
63- repository : ${{ env.DOCKER_RELEASE_REPO }}
64- registry : ${{ env.DOCKER_REGISTRY }}
65- tags : ${{ steps.tag.outputs.version }}
65+ - name : Prepare docker image tag
66+ id : prepare-docker-image-tag
67+ run : |
68+ REPOSITORY=${{ env.DOCKER_RELEASE_REPO }}
69+ TAG=${{ steps.tag.outputs.version }}
70+ TAGS="${REPOSITORY}:${TAG}"
71+ echo "tags=$TAGS" >> $GITHUB_OUTPUT
72+ - name : Push Atlas Operator to Registry
73+ uses : docker/build-push-action@v3
74+ with :
75+ context : .
76+ push : true
77+ tags : ${{ steps.prepare-docker-image-tag.outputs.tags }}
6678 build_args : VERSION=${{ steps.tag.outputs.tag }}
6779
68- - name : Push Atlas Operator to Quay Registry
69- uses : docker/build-push- action@v1
80+ - name : Login to Quay registry
81+ uses : docker/login- action@v2
7082 with :
83+ registry : ${{ env.QUAY_RELEASE_REGISTRY }}
7184 username : ${{ env.QUAY_ROBOT_NAME }}
7285 password : ${{ secrets.QUAY_PASSWORD }}
73- repository : ${{ env.QUAY_OPERATOR_REPO }}
74- registry : ${{ env.QUAY_RELEASE_REGISTRY }}
75- tags : ${{ steps.tag.outputs.version }}
86+ - name : Prepare docker Quay image tag
87+ id : prepare-quay-image-tag
88+ run : |
89+ REPOSITORY=${{ env.QUAY_OPERATOR_REPO }}
90+ TAG=${{ steps.tag.outputs.version }}
91+ TAGS="${REPOSITORY}:${TAG}"
92+ echo "tags=$TAGS" >> $GITHUB_OUTPUT
93+ - name : Push Atlas Operator to Quay Registry
94+ uses : docker/build-push-action@v3
95+ with :
96+ context : .
97+ push : true
98+ tags : ${{ steps.prepare-quay-image-tag.outputs.tags }}
7699 build_args : VERSION=${{ steps.tag.outputs.tag }}
77100
78101 - name : Now Prepare RedHadConnect image
@@ -82,14 +105,26 @@ jobs:
82105 VERSION : ${{ env.VERSION }}
83106 ENV : prod
84107
85- - name : Push Atlas Operator to RedHat Connect
86- uses : docker/build-push-action@v1
108+
109+ - name : Login to RedHat registry
110+ uses : docker/login-action@v2
87111 with :
112+ registry : ${{ env.REDHAT_SCAN_RELEASE_REGISTRY }}
88113 username : unused
89114 password : ${{ secrets.REDHAT_REGISTRY_PASSWORD }}
90- repository : ${{ env.REDHAT_SCAN_OPERATOR_REPO }}
91- registry : ${{ env.REDHAT_SCAN_RELEASE_REGISTRY }}
92- tags : ${{ steps.tag.outputs.version }}
115+ - name : Prepare docker Quay image tag
116+ id : prepare-redhat-image-tag
117+ run : |
118+ REPOSITORY=${{ env.REDHAT_SCAN_OPERATOR_REPO }}
119+ TAG=${{ steps.tag.outputs.version }}
120+ TAGS="${REPOSITORY}:${TAG}"
121+ echo "tags=$TAGS" >> $GITHUB_OUTPUT
122+ - name : Push Atlas Operator to RedHat Connect
123+ uses : docker/build-push-action@v3
124+ with :
125+ context : .
126+ push : true
127+ tags : ${{ steps.prepare-redhat-image-tag.outputs.tags }}
93128 labels : version=${{ steps.tag.outputs.version }}
94129 build_args : VERSION=${{ steps.tag.outputs.tag }}
95130
@@ -116,4 +151,4 @@ jobs:
116151 asset_name : atlas-operator-all-in-one-${{ steps.tag.outputs.version }}.tar.gz
117152 asset_content_type : application/tgz
118153
119- # TODO RedHad autopublish does not work. need to push bundles manually for now
154+ # TODO RedHad autopublish does not work. need to push bundles manually for now
0 commit comments