Skip to content

Commit

Permalink
Add "branch_name", "version" and "regorg" parameters to the
Browse files Browse the repository at this point in the history
"Provider Publish Service Artifacts" reusable workflow

Signed-off-by: Alper Rifat Ulucinar <[email protected]>
  • Loading branch information
ulucinar committed Oct 12, 2023
1 parent cdec277 commit f23acdf
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions .github/workflows/provider-publish-service-artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ on:
default: 'monolith'
required: false
type: string
regorg:
description: 'Package registry and organization where the packages will be pushed or (e.g. xpkg.upbound.io/upbound)'
default: 'xpkg.upbound.io/upbound'
required: false
type: string
size:
description: "Number of packages to build and push with each matrix build job"
default: '30'
Expand All @@ -18,6 +23,16 @@ on:
default: '1'
required: false
type: string
branch_name:
description: "Branch name to use while publishing the packages"
default: ''
required: false
type: string
version:
description: "Version string to use while publishing the packages"
default: ''
required: false
type: string
secrets:
UPBOUND_MARKETPLACE_PUSH_ROBOT_USR:
required: true
Expand Down Expand Up @@ -123,7 +138,7 @@ jobs:
if [ $num_packages -gt 10 ]; then
num_packages=10
fi
make -j $num_packages SUBPACKAGES="${{ steps.packages.outputs.target }}" XPKG_REG_ORGS=xpkg.upbound.io/upbound XPKG_REG_ORGS_NO_PROMOTE=xpkg.upbound.io/upbound build.all
make -j $num_packages SUBPACKAGES="${{ steps.packages.outputs.target }}" XPKG_REG_ORGS="${{ inputs.regorg }}" XPKG_REG_ORGS_NO_PROMOTE="${{ inputs.regorg }}" BRANCH_NAME="${{ inputs.branch_name }} VERSION="${{ inputs.version }}" build.all
echo "num_packages=$num_packages" >> $GITHUB_OUTPUT
env:
# We're using docker buildx, which doesn't actually load the images it
Expand All @@ -132,4 +147,4 @@ jobs:

- name: Publish Artifacts
run: |
make -j ${{ steps.build_artifacts.outputs.num_packages }} SUBPACKAGES="${{ steps.packages.outputs.target }}" XPKG_REG_ORGS=xpkg.upbound.io/upbound XPKG_REG_ORGS_NO_PROMOTE=xpkg.upbound.io/upbound CONCURRENCY="${{ inputs.concurrency }}" publish
make -j ${{ steps.build_artifacts.outputs.num_packages }} SUBPACKAGES="${{ steps.packages.outputs.target }}" XPKG_REG_ORGS="${{ inputs.regorg }}" XPKG_REG_ORGS_NO_PROMOTE="${{ inputs.regorg }}" CONCURRENCY="${{ inputs.concurrency }}" ${{ inputs.branch_name != "" && 'BRANCH_NAME=${{ inputs.branch_name }}' }} ${{ inputs.version != "" && 'VERSION=${{ inputs.version }}' }} publish

0 comments on commit f23acdf

Please sign in to comment.