Skip to content

Commit

Permalink
[Delete Custom Content] Add input - using (demisto#27859)
Browse files Browse the repository at this point in the history
* Add new input - instance_name

* pre-commit

* Update RN and Docker image

* Add pack ignore PB106
  • Loading branch information
mmhw authored and xsoar-bot committed Jul 26, 2023
1 parent e09b341 commit c0021e2
Show file tree
Hide file tree
Showing 7 changed files with 173 additions and 110 deletions.
2 changes: 1 addition & 1 deletion Packs/ContentManagement/.pack-ignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ ignore=RM106
ignore=PB106

[file:playbook-Delete_Custom_Content.yml]
ignore=PB105
ignore=PB105,PB106

[known_words]
cliname
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ tasks:
scriptarguments:
uri:
simple: /content/bundle
using:
simple: ${inputs.instance_name}
separatecontext: false
continueonerrortype: ""
view: |-
Expand Down Expand Up @@ -127,6 +129,8 @@ tasks:
simple: ${inputs.dry_run}
include_ids_dict:
simple: ${GetIdsFromCustomContent.included_ids}
using:
simple: ${inputs.instance_name}
separatecontext: false
continueonerrortype: ""
view: |-
Expand Down Expand Up @@ -400,6 +404,11 @@ inputs:
required: true
description: If true, will not actually delete any content entities.
playbookInputQuery:
- key: instance_name
value: {}
required: false
description: Core REST API instance name to use.
playbookInputQuery:
outputs: []
tests:
- No tests (auto formatted)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ core-api-download
| **Name** | **Description** | **Default Value** | **Required** |
| --- | --- | --- | --- |
| dry_run | If true, will not actually delete any content entities. | true | Required |
| instance_name | Core REST API instance name to use. | | Optional |

## Playbook Outputs

Expand Down
13 changes: 13 additions & 0 deletions Packs/ContentManagement/ReleaseNotes/1_2_10.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

#### Playbooks

##### Delete Custom Content

- Added new inputs `instance_name` (which `Core REST API` instance to use).

#### Scripts

##### DeleteContent
- Updated the Docker image to: *demisto/python3:3.10.12.63474*.

- Added the option to specify `Core REST API` instance to use by setting the **using** value when running the script.
254 changes: 147 additions & 107 deletions Packs/ContentManagement/Scripts/DeleteContent/DeleteContent.py

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ tags:
timeout: 3600
type: python
subtype: python3
dockerimage: demisto/python3:3.10.12.62631
dockerimage: demisto/python3:3.10.12.63474
tests:
- No tests (auto formatted)
fromversion: 6.0.0
Expand Down
2 changes: 1 addition & 1 deletion Packs/ContentManagement/pack_metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "XSOAR CI/CD",
"description": "This pack enables you to orchestrate your XSOAR system configuration.",
"support": "xsoar",
"currentVersion": "1.2.9",
"currentVersion": "1.2.10",
"author": "Cortex XSOAR",
"url": "https://www.paloaltonetworks.com/cortex",
"email": "",
Expand Down

0 comments on commit c0021e2

Please sign in to comment.