fix(bash): removed minus from env var names

This commit is contained in:
Richard Robert Reitz 2025-10-02 14:21:07 +02:00
parent 21eccc189b
commit 74edf65413
2 changed files with 8 additions and 6 deletions

View file

@ -3,10 +3,10 @@ description: 'Deploys an Edge Connect application using the edge-connect-client'
author: 'DevFW' author: 'DevFW'
inputs: inputs:
config-file: configFile:
description: 'Path to the Edge Connect configuration file.' description: 'Path to the Edge Connect configuration file.'
required: true required: true
dry-run: dryRun:
description: 'Perform a dry run of the deployment.' description: 'Perform a dry run of the deployment.'
required: false required: false
default: 'false' default: 'false'
@ -23,6 +23,6 @@ runs:
${{ github.action_path }}/endpoint.sh ${{ github.action_path }}/endpoint.sh
shell: bash shell: bash
env: env:
INPUT_CONFIG-FILE: ${{ inputs.config-file }} INPUT_CONFIG_FILE: ${{ inputs.configFile }}
INPUT_DRY-RUN: ${{ inputs.dry-run }} INPUT_DRY_RUN: ${{ inputs.dryRun }}
INPUT_VERSION: ${{ inputs.version }} INPUT_VERSION: ${{ inputs.version }}

View file

@ -15,12 +15,14 @@ main() {
chmod +x "${cli_path}" chmod +x "${cli_path}"
local -a args local -a args
args=("--file" "${INPUT_CONFIG-FILE}") args=("--file" "${INPUT_CONFIG_FILE}")
if [[ "${INPUT_DRY-RUN}" == "true" ]]; then if [[ "${INPUT_DRY_RUN}" == "true" ]]; then
args+=("--dry-run") args+=("--dry-run")
fi fi
echo Executing: "${cli_path}" apply "${args[@]}"
# The CLI uses an interactive prompt, so we need to pipe "yes" to it. # The CLI uses an interactive prompt, so we need to pipe "yes" to it.
yes | "${cli_path}" apply "${args[@]}" yes | "${cli_path}" apply "${args[@]}"
} }