diff --git a/README.md b/README.md index 49ca131..1f36e13 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,10 @@ This action posts the code and a SAST report to the Mobb vulnerability analysis **Optional** `true` or `false`. This requires `auto-pr` to be set to `true`. Once set, Fixes will be committed directly to the source branch. +## `organization-id` + +**Optional** The Organization ID to use with the Mobb platform. If not specified, the default organization will be used. + ## Outputs diff --git a/action.yml b/action.yml index 7780b6a..2a23d85 100644 --- a/action.yml +++ b/action.yml @@ -22,6 +22,9 @@ inputs: commit-directly: description: "Commit Directly flag, this requires Auto-PR flag to be set. Once enabled, Mobb will commit the fixes directly to the branch" required: false + organization-id: + description: "Organization ID" + required: false outputs: fix-report-url: @@ -47,6 +50,12 @@ runs: MobbExecString+=" --mobb-project-name \"${{ inputs.mobb-project-name }}\"" fi + # Check if organization-id exists and append it + if [ -n "${{ inputs.organization-id }}" ]; then + echo "organization-id specified: ${{ inputs.organization-id }}" + MobbExecString+=" --organization-id \"${{ inputs.organization-id }}\"" + fi + # Check if auto-pr flag is set append it if [ "${{ inputs.auto-pr }}" == "true" ]; then echo "Auto-PR flag is set"