Skip to content

Commit

Permalink
refactor docker.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
assignUser committed Dec 8, 2023
1 parent f956dab commit bd8038b
Showing 1 changed file with 30 additions and 37 deletions.
67 changes: 30 additions & 37 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,33 @@ permissions:

jobs:
linux:
name: "Build and Push ${{ matrix.name }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- name: Check
file: "scripts/check-container.dockfile"
args: "cpu_target=avx"
tags: "ghcr.io/facebookincubator/velox-dev:check-avx"
- name: CircleCI
file: "scripts/circleci-container.dockfile"
args: "cpu_target=avx"
tags: "ghcr.io/facebookincubator/velox-dev:circleci-avx"
- name: Check
file: "scripts/velox-torcharrow-container.dockfile"
args: "cpu_target=avx"
tags: "ghcr.io/facebookincubator/velox-dev:torcharrow-avx"
- name: Check
file: "scripts/ubuntu-22.04-cpp.dockerfile"
args: ""
tags: "ghcr.io/facebookincubator/velox-dev:amd64-ubuntu-22.04-avx"
- name: Presto Java
file: "scripts/prestojava-container.dockerfile"
args: "PRESTO_VERSION=0.284"
tags: "ghcr.io/facebookincubator/velox-dev:presto-java"

steps:
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
Expand All @@ -55,44 +81,11 @@ jobs:

- uses: actions/checkout@v3

- name: Build and Push check
uses: docker/build-push-action@v3
with:
context: scripts
file: scripts/check-container.dockfile
build-args: cpu_target=avx
push: ${{ github.repository == 'facebookincubator/velox' && github.event_name != 'pull_request'}}
tags: ghcr.io/facebookincubator/velox-dev:check-avx

- name: Build and Push circle-ci
- name: Build and Push
uses: docker/build-push-action@v3
with:
context: scripts
file: scripts/circleci-container.dockfile
build-args: cpu_target=avx
push: ${{ github.repository == 'facebookincubator/velox' && github.event_name != 'pull_request'}}
tags: ghcr.io/facebookincubator/velox-dev:circleci-avx

- name: Build and Push velox-torcharrow
uses: docker/build-push-action@v3
with:
context: scripts
file: scripts/velox-torcharrow-container.dockfile
build-args: cpu_target=avx
push: ${{ github.repository == 'facebookincubator/velox' && github.event_name != 'pull_request'}}
tags: ghcr.io/facebookincubator/velox-dev:torcharrow-avx

- name: Build and Push dev-image
uses: docker/build-push-action@v3
with:
file: scripts/ubuntu-22.04-cpp.dockerfile
push: ${{ github.repository == 'facebookincubator/velox' && github.event_name != 'pull_request'}}
tags: ghcr.io/facebookincubator/velox-dev:amd64-ubuntu-22.04-avx

- name: Build and Push Presto java dev-image
uses: docker/build-push-action@v3
with:
file: scripts/prestojava-container.dockerfile
build-args: PRESTO_VERSION=0.284
file: "${{ matrix.file }}"
build-args: "${{ matrix.args }}"
push: ${{ github.repository == 'facebookincubator/velox' && github.event_name != 'pull_request'}}
tags: ghcr.io/facebookincubator/velox-dev-presto-java:amd64-ubuntu-22.04-avx
tags: "${{ matrix.tags }}"

0 comments on commit bd8038b

Please sign in to comment.