From e67be4b19eed2532a25155d4a105eebc5d5f224c Mon Sep 17 00:00:00 2001 From: Lionello Lunesu Date: Fri, 30 Aug 2024 14:41:03 -0700 Subject: [PATCH] Change behavior to mode --- .github/workflows/test.yaml | 6 +++--- action.yaml | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 8c77b90..945603e 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -7,7 +7,7 @@ on: pull_request: branches: - '**' - workflow_dispatch: + workflow_dispatch: schedule: - cron: '0 0 * * *' @@ -30,7 +30,7 @@ jobs: config-env-vars: "DEFANG_GH_ACTION_TEST_MESSAGE" cwd: "./test" compose-files: "compose.yaml compose.prod.yaml" - behavior: "staging" + mode: "staging" env: DEFANG_GH_ACTION_TEST_MESSAGE: ${{ secrets.MESSAGE }} DEFANG_INTERNAL_TEST: dfng-test @@ -43,7 +43,7 @@ jobs: config-env-vars: "" cwd: "./test" compose-files: "" - behavior: "" + mode: "" env: DEFANG_INTERNAL_TEST: dfng-test diff --git a/action.yaml b/action.yaml index fbdf3fa..6dc7db6 100644 --- a/action.yaml +++ b/action.yaml @@ -22,10 +22,10 @@ inputs: description: "The compose files to deploy. Format 'file1 file2 file3'" required: false default: "" - behavior: - description: "The behavior of the deployment. Options: 'development', 'staging', 'production'" + mode: + description: "The deployment mode. Options: 'development', 'staging', 'production'" required: false - default: "development" + default: "" runs: using: "composite" @@ -69,12 +69,12 @@ runs: params+=("-f") params+=("$filename") done - if [[ -n "${{ inputs['behavior'] }}" ]]; then - params+=("--behavior=${{ inputs['behavior'] }}") + if [[ -n "${{ inputs['mode'] }}" ]]; then + params+=("--mode=${{ inputs['mode'] }}") fi if [[ "${DEFANG_INTERNAL_TEST}" == "dfng-test" ]]; then - # `defang compose up --dry-run` is used for testing as --behavior flag is only available to the "compose up" command + # `defang compose up --dry-run` is used for testing as --mode flag is only available to the "compose up" command echo defang compose "${params[@]}" up --dry-run defang compose "${params[@]}" up --dry-run else