|
19 | 19 | type: boolean |
20 | 20 | default: true |
21 | 21 | required: false |
22 | | - publish_docker: |
23 | | - description: 'Publish docker images' |
| 22 | + publish_image: |
| 23 | + description: 'Publish presto docker image' |
24 | 24 | type: boolean |
25 | 25 | default: true |
26 | 26 | required: false |
27 | | - publish_native_docker: |
28 | | - description: 'Publish native docker images' |
| 27 | + publish_native_image: |
| 28 | + description: 'Publish prestissimo docker image' |
29 | 29 | type: boolean |
30 | 30 | default: true |
31 | 31 | required: false |
32 | | - tag_image_as_latest: |
33 | | - description: 'Tag the image as latest' |
| 32 | + dependency_image: |
| 33 | + description: 'prestissimo dependency image(e.g., prestodb/presto-native-dependency:latest)' |
| 34 | + required: false |
| 35 | + default: '' |
| 36 | + publish_native_dep_image: |
| 37 | + description: 'Publish prestissimo dependency docker image' |
34 | 38 | type: boolean |
35 | 39 | default: true |
36 | 40 | required: false |
37 | | - dependency_image: |
38 | | - description: 'Dependency image(e.g., prestodb/presto-native-dependency:latest)' |
| 41 | + tag_image_as_latest: |
| 42 | + description: 'Tag the published images as latest' |
| 43 | + type: boolean |
| 44 | + default: true |
39 | 45 | required: false |
40 | | - default: '' |
41 | 46 | publish_docs: |
42 | 47 | description: 'Publish docs' |
43 | 48 | type: boolean |
|
96 | 101 | publish-maven-artifacts: |
97 | 102 | needs: publish-release-tag |
98 | 103 | if: | |
99 | | - (github.event.inputs.publish_maven == 'true' || github.event.inputs.publish_docker == 'true' || github.event.inputs.publish_docs == 'true') && |
| 104 | + (github.event.inputs.publish_maven == 'true' || github.event.inputs.publish_image == 'true' || github.event.inputs.publish_docs == 'true') && |
100 | 105 | (success() || (github.event.inputs.publish_release_tag != 'true' && !failure() && !cancelled())) |
101 | 106 | runs-on: ubuntu-latest |
102 | 107 | environment: release |
@@ -210,9 +215,9 @@ jobs: |
210 | 215 | -Pdeploy-to-ossrh \ |
211 | 216 | -pl '!presto-test-coverage' |
212 | 217 |
|
213 | | - publish-docker-images: |
| 218 | + publish-docker-image: |
214 | 219 | needs: publish-maven-artifacts |
215 | | - if: github.event.inputs.publish_docker == 'true' && !failure() && !cancelled() |
| 220 | + if: github.event.inputs.publish_image == 'true' && !failure() && !cancelled() |
216 | 221 | runs-on: ubuntu-latest |
217 | 222 | environment: release |
218 | 223 | timeout-minutes: 150 |
@@ -267,10 +272,10 @@ jobs: |
267 | 272 | ${{ env.DOCKER_REPO }}:${{ env.RELEASE_TAG }} |
268 | 273 | ${{ github.event.inputs.tag_image_as_latest == 'true' && format('{0}:latest', env.DOCKER_REPO) || '' }} |
269 | 274 |
|
270 | | - publish-native-images: |
| 275 | + publish-native-image: |
271 | 276 | needs: publish-release-tag |
272 | 277 | if: | |
273 | | - github.event.inputs.publish_native_docker == 'true' && |
| 278 | + github.event.inputs.publish_native_image == 'true' && |
274 | 279 | (success() || (github.event.inputs.publish_release_tag != 'true' && !failure() && !cancelled())) |
275 | 280 | runs-on: ubuntu-latest |
276 | 281 | permissions: |
@@ -315,8 +320,15 @@ jobs: |
315 | 320 | else |
316 | 321 | echo "Building new depedency image" |
317 | 322 | docker compose build centos-native-dependency |
318 | | - docker tag presto/prestissimo-dependency:centos9 ${{ github.repository_owner }}/presto-native-dependency:${{ env.RELEASE_TAG }}-${{ env.COMMIT_SHA }} |
319 | | - docker push ${{ github.repository_owner }}/presto-native-dependency:${{ env.RELEASE_TAG }}-${{ env.COMMIT_SHA }} |
| 323 | + if [[ "${{ github.event.inputs.publish_native_dep_image }}" == "true" ]]; then |
| 324 | + docker tag presto/prestissimo-dependency:centos9 ${{ github.repository_owner }}/presto-native-dependency:${{ env.RELEASE_TAG }}-${{ env.COMMIT_SHA }} |
| 325 | + docker push ${{ github.repository_owner }}/presto-native-dependency:${{ env.RELEASE_TAG }}-${{ env.COMMIT_SHA }} |
| 326 | + |
| 327 | + if [[ "${{ github.event.inputs.tag_image_as_latest }}" == "true" ]]; then |
| 328 | + docker tag presto/prestissimo-dependency:centos9 ${{ github.repository_owner }}/presto-native-dependency:latest |
| 329 | + docker push ${{ github.repository_owner }}/presto-native-dependency:latest |
| 330 | + fi |
| 331 | + fi |
320 | 332 | fi |
321 | 333 | docker images |
322 | 334 |
|
@@ -442,4 +454,3 @@ jobs: |
442 | 454 | run: | |
443 | 455 | cd ${{ github.workspace }}/prestodb.github.io |
444 | 456 | gh pr create --title "Add ${RELEASE_TAG} docs" --body "Add ${RELEASE_TAG} docs" --base source --head "${RELEASE_TAG}-docs" |
445 | | -
|
|
0 commit comments