Skip to content

Commit

Permalink
handle defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
m2Giles committed Nov 2, 2024
1 parent b05c715 commit 757df34
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 54 deletions.
23 changes: 6 additions & 17 deletions .github/workflows/build-image-beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,33 +18,22 @@ on:
workflow_dispatch:
inputs:
base_name:
default: 'bluefin'
description: 'Image Brand to Build'
default: '["bluefin"]'
type: choice
options:
- bluefin
- aurora
- '["bluefin"]'
- '["aurora"]'
- '["bluefin", "aurora"]'

jobs:
build-image-beta:
if: github.event_name != 'workflow_dispatch'
name: Build Beta Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
base_name: ${{ fromJson(inputs.base_name) || fromJson('["bluefin", "aurora"]') }}
with:
base_name: ${{ matrix.base_name }}
fedora_version: beta

build-image-beta-call:
if: github.event_name == 'workflow_dispatch'
name: Build Latest Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
with:
base_name: ${{ inputs.base_name }}
fedora_version: latest
25 changes: 6 additions & 19 deletions .github/workflows/build-image-latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,35 +18,22 @@ on:
workflow_dispatch:
inputs:
base_name:
default: 'bluefin'
description: 'Image Brand to Build'
default: '["bluefin"]'
type: choice
options:
- bluefin
- aurora
- '["bluefin"]'
- '["aurora"]'
- '["bluefin", "aurora"]'

jobs:
build-image-latest:
if: github.event_name != 'workflow_dispatch'
name: Build Latest Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
base_name: ${{ fromJson(inputs.base_name) || fromJson('["bluefin", "aurora"]') }}
with:
image_flavors: "['main', 'nvidia', 'hwe', 'hwe-nvidia']"
base_name: ${{ matrix.base_name }}
fedora_version: latest

build-image-latest-call:
if: github.event_name == 'workflow_dispatch'
name: Build Latest Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
with:
image_flavors: "['main', 'nvidia', 'hwe', 'hwe-nvidia']"
base_name: ${{ inputs.base_name }}
fedora_version: latest
24 changes: 6 additions & 18 deletions .github/workflows/build-image-stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,22 @@ on:
workflow_dispatch:
inputs:
base_name:
default: 'bluefin'
description: 'Image Brand to Build'
default: '["bluefin"]'
type: choice
options:
- bluefin
- aurora
- '["bluefin"]'
- '["aurora"]'
- '["bluefin", "aurora"]'

jobs:
build-image-stable:
if: github.event_name != 'workflow_dispatch'
name: Build Stable Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
base_name: ${{ fromJson(inputs.base_name) || fromJson('["bluefin", "aurora"]') }}
with:
base_name: ${{ matrix.base_name }}
fedora_version: stable

build-image-stable-call:
if: github.event_name == 'workflow_dispatch'
name: Build Latest Images
uses: ./.github/workflows/reusable-build.yml
secrets: inherit
strategy:
matrix:
base_name: [bluefin, aurora]
with:
base_name: ${{ inputs.base_name }}
fedora_version: latest

0 comments on commit 757df34

Please sign in to comment.