Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions .github/workflows/docker-multistage-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ on:
description: 'The build matrix'
required: true
type: string
flavour:
description: 'The flavour to build (Examples: base, mods, prod or work).'
stage:
description: 'The stage to build (Examples: base, mods, prod or work).'
required: true
type: string
flavour_prev:
description: 'The previous flavour (used for downloading previous artifact).'
stage_prev:
description: 'The previous stage (used for downloading previous artifact).'
required: true
type: string
artifact_prefix:
Expand All @@ -41,7 +41,7 @@ jobs:
# JOB: BUILD
# -----------------------------------------------------------------------------------------------
build:
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.flavour }} (${{ matrix.arch }}) ${{ matrix.refs }}
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.stage }} (${{ matrix.arch }}) ${{ matrix.refs }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -78,8 +78,8 @@ jobs:
VERSION="${{ matrix.version }}"
ARCH="$( echo "${{ matrix.arch }}" | sed 's|/|-|g' )"

NAME_PREV="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.flavour_prev }}"
NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.flavour }}"
NAME_PREV="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.stage_prev }}"
NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.stage }}"
echo "::set-output name=prev::${NAME_PREV}"
echo "::set-output name=curr::${NAME_CURR}"

Expand All @@ -99,14 +99,14 @@ jobs:
name: ${{ steps.set-artifact-name.outputs.prev }}
attempt_limit: 20
attempt_delay: 10000
if: ${{ inputs.flavour_prev != '' }}
if: ${{ inputs.stage_prev != '' }}

- name: "[Artifact Load] Import previously built image"
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make load INFILE=${{ steps.set-artifact-name.outputs.prev }}
if: ${{ inputs.flavour_prev != '' }}
if: ${{ inputs.stage_prev != '' }}


# ------------------------------------------------------------
Expand All @@ -116,7 +116,7 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make build VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} ARCH=${{ matrix.arch }}
make build VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} ARCH=${{ matrix.arch }}


# ------------------------------------------------------------
Expand All @@ -126,7 +126,7 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make test VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} ARCH=${{ matrix.arch }}
make test VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} ARCH=${{ matrix.arch }}
if: ${{ inputs.run_tests }}


Expand All @@ -141,7 +141,7 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make save-verify VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} ARCH=${{ matrix.arch }} OUTFILE=${{ steps.set-artifact-name.outputs.curr }} INFILE=${{ steps.set-artifact-name.outputs.curr }}
make save-verify VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} ARCH=${{ matrix.arch }} OUTFILE=${{ steps.set-artifact-name.outputs.curr }} INFILE=${{ steps.set-artifact-name.outputs.curr }}
if: ${{ inputs.upload_artifact }}

###
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/docker-multistage-push-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ on:
description: 'The build matrix'
required: true
type: string
flavour:
description: 'The flavour to build (Examples: base, mods, prod or work).'
stage:
description: 'The stage to build (Examples: base, mods, prod or work).'
required: true
type: string
artifact_prefix:
Expand Down Expand Up @@ -43,7 +43,7 @@ jobs:
# JOB: DEPLOY
# -----------------------------------------------------------------------------------------------
test:
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.flavour }} (${{ matrix.arch }}) ${{ matrix.refs }}
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.stage }} (${{ matrix.arch }}) ${{ matrix.refs }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -84,7 +84,7 @@ jobs:
VERSION="${{ matrix.version }}"
ARCH="$( echo "${{ matrix.arch }}" | sed 's|/|-|g' )"

NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.flavour }}"
NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.stage }}"
echo "::set-output name=curr::${NAME_CURR}"


Expand Down Expand Up @@ -118,7 +118,7 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make tag VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}
make tag VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}

- name: "[Docker Tag] Show images"
run: |
Expand All @@ -143,5 +143,5 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make push VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}
make push VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}
if: ${{ inputs.can_deploy }}
10 changes: 5 additions & 5 deletions .github/workflows/docker-multistage-push-manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ on:
description: 'The build matrix set via params.yml.'
required: true
type: string
flavour:
description: 'The flavour to build (Examples: base, mods, prod or work).'
stage:
description: 'The stage to build (Examples: base, mods, prod or work).'
required: true
type: string
can_deploy:
Expand Down Expand Up @@ -43,7 +43,7 @@ jobs:
# JOB (3/3): DEPLOY
# -----------------------------------------------------------------------------------------------
deploy:
name: ${{ matrix.name }}-${{ matrix.version }} (${{ matrix.flavour }}) ${{ matrix.refs }}
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.stage }} ${{ matrix.refs }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -107,7 +107,7 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make manifest-create VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} ARCHES=${{ steps.manifest.outputs.arches }} TAG=${{ steps.tag.outputs.docker-tag }}
make manifest-create VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} ARCHES=${{ steps.manifest.outputs.arches }} TAG=${{ steps.tag.outputs.docker-tag }}


# ------------------------------------------------------------
Expand All @@ -117,4 +117,4 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make manifest-push VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}
make manifest-push VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} TAG=${{ steps.tag.outputs.docker-tag }}
10 changes: 5 additions & 5 deletions .github/workflows/docker-multistage-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ on:
description: 'The build matrix'
required: true
type: string
flavour:
description: 'The flavour to build (Examples: base, mods, prod or work).'
stage:
description: 'The stage to build (Examples: base, mods, prod or work).'
required: true
type: string
artifact_prefix:
Expand All @@ -29,7 +29,7 @@ jobs:
# JOB: BUILD
# -----------------------------------------------------------------------------------------------
test:
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.flavour }} (${{ matrix.arch }}) ${{ matrix.refs }}
name: ${{ matrix.name }}-${{ matrix.version }}-${{ inputs.stage }} (${{ matrix.arch }}) ${{ matrix.refs }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -66,7 +66,7 @@ jobs:
VERSION="${{ matrix.version }}"
ARCH="$( echo "${{ matrix.arch }}" | sed 's|/|-|g' )"

NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.flavour }}"
NAME_CURR="${{ inputs.artifact_prefix }}-${PRE_HASH}-${VERSION}-${ARCH}-${{ inputs.stage }}"
echo "::set-output name=curr::${NAME_CURR}"


Expand Down Expand Up @@ -100,4 +100,4 @@ jobs:
uses: cytopia/shell-command-retry-action@v0.1.2
with:
command: |
make test VERSION=${{ matrix.version }} FLAVOUR=${{ inputs.flavour }} ARCH=${{ matrix.arch }}
make test VERSION=${{ matrix.version }} STAGE=${{ inputs.stage }} FLAVOUR=${{ matrix.flavour }} ARCH=${{ matrix.arch }}