diff --git a/README.md b/README.md index f115520c..340dfd98 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ steps: | `server` | The instance URL hosting Octopus Deploy (i.e. ""). The instance URL is required, but you may also use the OCTOPUS_URL environment variable. | | `api_key` | The API key used to access Octopus Deploy. An API key is required, but you may also use the OCTOPUS_API_KEY environment variable. It is strongly recommended that this value retrieved from a GitHub secret. | | `space` | The name of a space within which this command will be executed. The space name is required, but you may also use the OCTOPUS_SPACE environment variable. | -| `gitRef` | The Git Reference on which to run the Runbook. If not populate the action assumes you are running a DB Runbook. In most cases when running a Git Runbook this will be your default branch refs/heads/main | +| `git_ref` | The Git Reference on which to run the Runbook. If not populate the action assumes you are running a DB Runbook. In most cases when running a Git Runbook this will be your default branch refs/heads/main | ## 📤 Outputs diff --git a/action.yml b/action.yml index b16acce7..9e9fe8ab 100644 --- a/action.yml +++ b/action.yml @@ -30,7 +30,7 @@ inputs: description: 'The API key used to access Octopus Deploy. An API key is required, but you may also use the OCTOPUS_API_KEY environment variable. It is strongly recommended that this value retrieved from a GitHub secret.' space: description: 'The name of a space within which this command will be executed. The space name is required, but you may also use the OCTOPUS_SPACE environment variable.' - gitRef: + git_ref: description: 'The Git Reference on which to run the Runbook. If not populate the action assumes you are running a DB Runbook. In most cases when running a Git Runbook this will be your default branch refs/heads/main' outputs: diff --git a/src/api-wrapper.ts b/src/api-wrapper.ts index 369757d5..24046a6e 100644 --- a/src/api-wrapper.ts +++ b/src/api-wrapper.ts @@ -17,6 +17,8 @@ export interface RunbookRunResult { } export async function runRunbookFromInputs(client: Client, parameters: InputParameters): Promise { + client.info(`🐙 Running runbooks in Octopus Deploy with GitRef ${parameters.gitRef}...`) + if (parameters.gitRef) { return await runGitRunbookFromInputs(client, parameters) } @@ -25,7 +27,7 @@ export async function runRunbookFromInputs(client: Client, parameters: InputPara } async function runGitRunbookFromInputs(client: Client, parameters: InputParameters): Promise { - client.info('🐙 Running runbooks in Octopus Deploy...') + client.info('🐙 Running Git runbooks in Octopus Deploy...') const command: RunGitRunbookCommand = { spaceName: parameters.space, @@ -50,7 +52,7 @@ async function runGitRunbookFromInputs(client: Client, parameters: InputParamete } async function runDbRunbookFromInputs(client: Client, parameters: InputParameters): Promise { - client.info('🐙 Running runbooks in Octopus Deploy...') + client.info('🐙 Running DB runbooks in Octopus Deploy...') const command: CreateRunbookRunCommandV1 = { spaceName: parameters.space, diff --git a/src/input-parameters.ts b/src/input-parameters.ts index 25d20730..f2bcdd0c 100644 --- a/src/input-parameters.ts +++ b/src/input-parameters.ts @@ -46,7 +46,7 @@ export function getInputParameters(): InputParameters { tenantTags: getMultilineInput('tenant_tags').map(p => p.trim()) || undefined, useGuidedFailure: getBooleanInput('use_guided_failure') || undefined, variables: variablesMap, - gitRef: getInput('git-ref') || undefined + gitRef: getInput('git_ref') || undefined } const errors: string[] = []