-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Run image builds as separate jobs (#1157)
* Run image builds as separate jobs Signed-off-by: Paul S. Schweigert <[email protected]> We found that running all image builds as a single job could create a bottleneck, so we decided to split them into separate jobs. This should also make reviewing logs easier, as there should be less output for the web UI to have to render. * upgrade pip Signed-off-by: Paul S. Schweigert <[email protected]> --------- Signed-off-by: Paul S. Schweigert <[email protected]>
- Loading branch information
Showing
3 changed files
with
66 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,47 @@ | ||
name: 'Build and push images' | ||
description: 'Builds and pushes images to remote repository' | ||
inputs: | ||
name: | ||
description: 'Image name' | ||
required: true | ||
tag: | ||
description: 'Tag of image that will be build' | ||
description: 'Release version' | ||
required: true | ||
dockerfile: | ||
description: 'Location of dockerfile' | ||
required: true | ||
platforms: | ||
description: '(optional) platform to build image for' | ||
required: false | ||
default: "linux/amd64" | ||
repository: | ||
description: '(optional) repository' | ||
required: false | ||
default: 'icr.io/quantum-public' | ||
pythonversion: | ||
description: '(optional) python version' | ||
required: false | ||
default: '' | ||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Build and push node image [3.8] | ||
uses: docker/build-push-action@v3 | ||
- name: Build and push image with Python Version | ||
if: ${{inputs.pythonversion}} != '' | ||
uses: docker/build-push-action@v5 | ||
with: | ||
platforms: ${{inputs.platforms}} | ||
context: . | ||
file: Dockerfile-ray-node | ||
file: ${{inputs.dockerfile}} | ||
push: true | ||
tags: icr.io/quantum-public/quantum-serverless-ray-node:${{inputs.tag}}-py38,icr.io/quantum-public/quantum-serverless-ray-node:latest-py38 | ||
tags: ${{inputs.repository}}/${{inputs.name}}:${{inputs.tag}}-${{inputs.pythonversion}},${{inputs.repository}}/${{inputs.name}}:latest-${{inputs.pythonversion}} | ||
build-args: | ||
IMAGE_PY_VERSION=py38 | ||
- name: Build and push node image [3.9] | ||
uses: docker/build-push-action@v3 | ||
with: | ||
platforms: linux/amd64,linux/arm64 | ||
context: . | ||
file: Dockerfile-ray-node | ||
push: true | ||
tags: icr.io/quantum-public/quantum-serverless-ray-node:${{inputs.tag}}-py39,icr.io/quantum-public/quantum-serverless-ray-node:latest-py39 | ||
build-args: | ||
IMAGE_PY_VERSION=py39 | ||
- name: Build and push node image [3.10] | ||
uses: docker/build-push-action@v3 | ||
with: | ||
context: . | ||
file: Dockerfile-ray-node | ||
push: true | ||
tags: icr.io/quantum-public/quantum-serverless-ray-node:${{inputs.tag}}-py310,icr.io/quantum-public/quantum-serverless-ray-node:latest-py310 | ||
build-args: | ||
IMAGE_PY_VERSION=py310 | ||
- name: Build and push repository server | ||
uses: docker/build-push-action@v3 | ||
with: | ||
platforms: linux/amd64,linux/arm64 | ||
context: . | ||
file: ./repository/Dockerfile | ||
push: true | ||
tags: icr.io/quantum-public/quantum-repository-server:${{inputs.tag}},icr.io/quantum-public/quantum-repository-server:latest | ||
- name: Build and push gateway | ||
uses: docker/build-push-action@v3 | ||
IMAGE_PY_VERSION=${{inputs.pythonversion}} | ||
- name: Build and push image | ||
if: ${{inputs.pythonversion}} == '' | ||
uses: docker/build-push-action@v5 | ||
with: | ||
platforms: linux/amd64,linux/arm64 | ||
platforms: ${{inputs.platforms}} | ||
context: . | ||
file: ./gateway/Dockerfile | ||
file: ${{inputs.dockerfile}} | ||
push: true | ||
tags: icr.io/quantum-public/quantum-serverless-gateway:${{inputs.tag}},icr.io/quantum-public/quantum-serverless-gateway:latest | ||
tags: ${{inputs.repository}}/${{inputs.name}}:${{inputs.tag}},${{inputs.repository}}/${{inputs.name}}:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters