Add Operand #3
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
name: Add Operand | |
on: | |
workflow_call: | |
inputs: | |
image: | |
description: "The FQN of the Operand image" | |
required: true | |
type: string | |
version: | |
description: "The upstream-version of the Operand" | |
type: string | |
ref: | |
description: "The git reference to checkout" | |
required: false | |
default: main | |
type: string | |
repository: | |
description: "The git repository to checkout" | |
required: false | |
type: string | |
workflow_dispatch: | |
inputs: | |
image: | |
description: "The FQN of the Operand image" | |
required: true | |
type: string | |
version: | |
description: "The upstream-version of the Operand" | |
type: string | |
ref: | |
description: "The git reference to checkout" | |
required: false | |
default: main | |
type: string | |
repository: | |
description: "The git repository to checkout" | |
required: false | |
type: string | |
jobs: | |
add-operand: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ inputs.ref }} | |
repository: ${{ inputs.repository }} | |
token: ${{ secrets.INFINISPAN_RELEASE_TOKEN }} | |
- name: Determine Upstream Version | |
run: | | |
if [[ -z "${{ inputs.version }}" ]]; then | |
IMAGE=${{ inputs.image }} | |
TAG=${IMAGE#*:} | |
echo VERSION=${TAG%.Final} >> ${GITHUB_ENV} | |
else | |
echo VERSION=${{ inputs.version }} >> ${GITHUB_ENV} | |
fi | |
- name: Add Operand | |
run: ./scripts/ci/add_operand.sh | |
env: | |
IMAGE: ${{ inputs.image }} | |
VERSION: ${{ env.VERSION }} | |
- name: Commit changes and push to repository | |
run: | | |
git config user.email "[email protected]" | |
git config user.name "Infinispan" | |
git add config/manager/manager.yaml documentation/asciidoc/topics/attributes/community-attributes.adoc documentation/asciidoc/topics/supported_operands/ | |
git commit -m "Add Operand ${{ env.VERSION }}" | |
git push |