artifactory.PackageCleanupPolicy
Explore with Pulumi AI
Import
$ pulumi import artifactory:index/packageCleanupPolicy:PackageCleanupPolicy my-cleanup-policy my-policy
$ pulumi import artifactory:index/packageCleanupPolicy:PackageCleanupPolicy my-cleanup-policy my-policy:myproj
Create PackageCleanupPolicy Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new PackageCleanupPolicy(name: string, args: PackageCleanupPolicyArgs, opts?: CustomResourceOptions);
@overload
def PackageCleanupPolicy(resource_name: str,
args: PackageCleanupPolicyArgs,
opts: Optional[ResourceOptions] = None)
@overload
def PackageCleanupPolicy(resource_name: str,
opts: Optional[ResourceOptions] = None,
key: Optional[str] = None,
search_criteria: Optional[PackageCleanupPolicySearchCriteriaArgs] = None,
cron_expression: Optional[str] = None,
description: Optional[str] = None,
duration_in_minutes: Optional[int] = None,
enabled: Optional[bool] = None,
skip_trashcan: Optional[bool] = None)
func NewPackageCleanupPolicy(ctx *Context, name string, args PackageCleanupPolicyArgs, opts ...ResourceOption) (*PackageCleanupPolicy, error)
public PackageCleanupPolicy(string name, PackageCleanupPolicyArgs args, CustomResourceOptions? opts = null)
public PackageCleanupPolicy(String name, PackageCleanupPolicyArgs args)
public PackageCleanupPolicy(String name, PackageCleanupPolicyArgs args, CustomResourceOptions options)
type: artifactory:PackageCleanupPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args PackageCleanupPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args PackageCleanupPolicyArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args PackageCleanupPolicyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args PackageCleanupPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args PackageCleanupPolicyArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var packageCleanupPolicyResource = new Artifactory.PackageCleanupPolicy("packageCleanupPolicyResource", new()
{
Key = "string",
SearchCriteria = new Artifactory.Inputs.PackageCleanupPolicySearchCriteriaArgs
{
IncludedPackages = new[]
{
"string",
},
Repos = new[]
{
"string",
},
PackageTypes = new[]
{
"string",
},
IncludedProjects = new[]
{
"string",
},
ExcludedProperties =
{
{ "string", new[]
{
"string",
} },
},
IncludeAllProjects = false,
ExcludedRepos = new[]
{
"string",
},
CreatedBeforeInDays = 0,
IncludedProperties =
{
{ "string", new[]
{
"string",
} },
},
KeepLastNVersions = 0,
LastDownloadedBeforeInDays = 0,
ExcludedPackages = new[]
{
"string",
},
},
CronExpression = "string",
Description = "string",
DurationInMinutes = 0,
Enabled = false,
SkipTrashcan = false,
});
example, err := artifactory.NewPackageCleanupPolicy(ctx, "packageCleanupPolicyResource", &artifactory.PackageCleanupPolicyArgs{
Key: pulumi.String("string"),
SearchCriteria: &artifactory.PackageCleanupPolicySearchCriteriaArgs{
IncludedPackages: pulumi.StringArray{
pulumi.String("string"),
},
Repos: pulumi.StringArray{
pulumi.String("string"),
},
PackageTypes: pulumi.StringArray{
pulumi.String("string"),
},
IncludedProjects: pulumi.StringArray{
pulumi.String("string"),
},
ExcludedProperties: pulumi.StringArrayMap{
"string": pulumi.StringArray{
pulumi.String("string"),
},
},
IncludeAllProjects: pulumi.Bool(false),
ExcludedRepos: pulumi.StringArray{
pulumi.String("string"),
},
CreatedBeforeInDays: pulumi.Int(0),
IncludedProperties: pulumi.StringArrayMap{
"string": pulumi.StringArray{
pulumi.String("string"),
},
},
KeepLastNVersions: pulumi.Int(0),
LastDownloadedBeforeInDays: pulumi.Int(0),
ExcludedPackages: pulumi.StringArray{
pulumi.String("string"),
},
},
CronExpression: pulumi.String("string"),
Description: pulumi.String("string"),
DurationInMinutes: pulumi.Int(0),
Enabled: pulumi.Bool(false),
SkipTrashcan: pulumi.Bool(false),
})
var packageCleanupPolicyResource = new PackageCleanupPolicy("packageCleanupPolicyResource", PackageCleanupPolicyArgs.builder()
.key("string")
.searchCriteria(PackageCleanupPolicySearchCriteriaArgs.builder()
.includedPackages("string")
.repos("string")
.packageTypes("string")
.includedProjects("string")
.excludedProperties(Map.of("string", "string"))
.includeAllProjects(false)
.excludedRepos("string")
.createdBeforeInDays(0)
.includedProperties(Map.of("string", "string"))
.keepLastNVersions(0)
.lastDownloadedBeforeInDays(0)
.excludedPackages("string")
.build())
.cronExpression("string")
.description("string")
.durationInMinutes(0)
.enabled(false)
.skipTrashcan(false)
.build());
package_cleanup_policy_resource = artifactory.PackageCleanupPolicy("packageCleanupPolicyResource",
key="string",
search_criteria={
"included_packages": ["string"],
"repos": ["string"],
"package_types": ["string"],
"included_projects": ["string"],
"excluded_properties": {
"string": ["string"],
},
"include_all_projects": False,
"excluded_repos": ["string"],
"created_before_in_days": 0,
"included_properties": {
"string": ["string"],
},
"keep_last_n_versions": 0,
"last_downloaded_before_in_days": 0,
"excluded_packages": ["string"],
},
cron_expression="string",
description="string",
duration_in_minutes=0,
enabled=False,
skip_trashcan=False)
const packageCleanupPolicyResource = new artifactory.PackageCleanupPolicy("packageCleanupPolicyResource", {
key: "string",
searchCriteria: {
includedPackages: ["string"],
repos: ["string"],
packageTypes: ["string"],
includedProjects: ["string"],
excludedProperties: {
string: ["string"],
},
includeAllProjects: false,
excludedRepos: ["string"],
createdBeforeInDays: 0,
includedProperties: {
string: ["string"],
},
keepLastNVersions: 0,
lastDownloadedBeforeInDays: 0,
excludedPackages: ["string"],
},
cronExpression: "string",
description: "string",
durationInMinutes: 0,
enabled: false,
skipTrashcan: false,
});
type: artifactory:PackageCleanupPolicy
properties:
cronExpression: string
description: string
durationInMinutes: 0
enabled: false
key: string
searchCriteria:
createdBeforeInDays: 0
excludedPackages:
- string
excludedProperties:
string:
- string
excludedRepos:
- string
includeAllProjects: false
includedPackages:
- string
includedProjects:
- string
includedProperties:
string:
- string
keepLastNVersions: 0
lastDownloadedBeforeInDays: 0
packageTypes:
- string
repos:
- string
skipTrashcan: false
PackageCleanupPolicy Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The PackageCleanupPolicy resource accepts the following input properties:
- Key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- Search
Criteria PackageCleanup Policy Search Criteria - Cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- Description string
- Duration
In intMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- Enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- Skip
Trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- Key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- Search
Criteria PackageCleanup Policy Search Criteria Args - Cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- Description string
- Duration
In intMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- Enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- Skip
Trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- key String
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria PackageCleanup Policy Search Criteria - cron
Expression String - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description String
- duration
In IntegerMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled Boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- skip
Trashcan Boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria PackageCleanup Policy Search Criteria - cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description string
- duration
In numberMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- skip
Trashcan boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- key str
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search_
criteria PackageCleanup Policy Search Criteria Args - cron_
expression str - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description str
- duration_
in_ intminutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- skip_
trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- key String
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria Property Map - cron
Expression String - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description String
- duration
In NumberMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled Boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- skip
Trashcan Boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
Outputs
All input properties are implicitly available as output properties. Additionally, the PackageCleanupPolicy resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing PackageCleanupPolicy Resource
Get an existing PackageCleanupPolicy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: PackageCleanupPolicyState, opts?: CustomResourceOptions): PackageCleanupPolicy
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
cron_expression: Optional[str] = None,
description: Optional[str] = None,
duration_in_minutes: Optional[int] = None,
enabled: Optional[bool] = None,
key: Optional[str] = None,
search_criteria: Optional[PackageCleanupPolicySearchCriteriaArgs] = None,
skip_trashcan: Optional[bool] = None) -> PackageCleanupPolicy
func GetPackageCleanupPolicy(ctx *Context, name string, id IDInput, state *PackageCleanupPolicyState, opts ...ResourceOption) (*PackageCleanupPolicy, error)
public static PackageCleanupPolicy Get(string name, Input<string> id, PackageCleanupPolicyState? state, CustomResourceOptions? opts = null)
public static PackageCleanupPolicy get(String name, Output<String> id, PackageCleanupPolicyState state, CustomResourceOptions options)
resources: _: type: artifactory:PackageCleanupPolicy get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- Description string
- Duration
In intMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- Enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- Key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- Search
Criteria PackageCleanup Policy Search Criteria - Skip
Trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- Cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- Description string
- Duration
In intMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- Enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- Key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- Search
Criteria PackageCleanup Policy Search Criteria Args - Skip
Trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- cron
Expression String - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description String
- duration
In IntegerMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled Boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- key String
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria PackageCleanup Policy Search Criteria - skip
Trashcan Boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- cron
Expression string - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description string
- duration
In numberMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- key string
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria PackageCleanup Policy Search Criteria - skip
Trashcan boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- cron_
expression str - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description str
- duration_
in_ intminutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled bool
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- key str
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search_
criteria PackageCleanup Policy Search Criteria Args - skip_
trashcan bool - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
- cron
Expression String - The cron expression that determines when the policy is run, However if left empty the policy will not run automatically and can only be triggered manually.
- description String
- duration
In NumberMinutes - The maximum duration (in minutes) for policy execution, after which the policy will stop running even if not completed. While setting a maximum run duration for a policy is useful for adhering to a strict cleanup schedule, it can cause the policy to stop before completion.
- enabled Boolean
- A cleanup policy must be created inactive. But if used it must be set to
false
. If set totrue
when calling this API, the API call will fail and an error message is received. Defaults totrue
- key String
- An ID that is used to identify the cleanup policy. A minimum of three characters is required and can include letters, numbers, underscore and hyphen.
- search
Criteria Property Map - skip
Trashcan Boolean - A true value means that when this policy is executed, packages will be permanently deleted. false means that when the policy is executed packages will be deleted to the Trash Can. Defaults to
false
.
Supporting Types
PackageCleanupPolicySearchCriteria, PackageCleanupPolicySearchCriteriaArgs
- Included
Packages List<string> - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- Included
Projects List<string> - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - Package
Types List<string> - Repos List<string>
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- Created
Before intIn Days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- Created
Before intIn Months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- Excluded
Packages List<string> - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- Excluded
Properties Dictionary<string, ImmutableArray<string>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- Excluded
Repos List<string> - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- Include
All boolProjects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- Included
Properties Dictionary<string, ImmutableArray<string>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- Keep
Last intNVersions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- Last
Downloaded intBefore In Days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- Last
Downloaded intBefore In Months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
- Included
Packages []string - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- Included
Projects []string - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - Package
Types []string - Repos []string
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- Created
Before intIn Days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- Created
Before intIn Months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- Excluded
Packages []string - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- Excluded
Properties map[string][]string - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- Excluded
Repos []string - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- Include
All boolProjects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- Included
Properties map[string][]string - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- Keep
Last intNVersions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- Last
Downloaded intBefore In Days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- Last
Downloaded intBefore In Months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
- included
Packages List<String> - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- included
Projects List<String> - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - package
Types List<String> - repos List<String>
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- created
Before IntegerIn Days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- created
Before IntegerIn Months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- excluded
Packages List<String> - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- excluded
Properties Map<String,List<String>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- excluded
Repos List<String> - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- include
All BooleanProjects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- included
Properties Map<String,List<String>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- keep
Last IntegerNVersions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- last
Downloaded IntegerBefore In Days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- last
Downloaded IntegerBefore In Months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
- included
Packages string[] - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- included
Projects string[] - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - package
Types string[] - repos string[]
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- created
Before numberIn Days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- created
Before numberIn Months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- excluded
Packages string[] - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- excluded
Properties {[key: string]: string[]} - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- excluded
Repos string[] - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- include
All booleanProjects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- included
Properties {[key: string]: string[]} - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- keep
Last numberNVersions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- last
Downloaded numberBefore In Days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- last
Downloaded numberBefore In Months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
- included_
packages Sequence[str] - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- included_
projects Sequence[str] - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - package_
types Sequence[str] - repos Sequence[str]
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- created_
before_ intin_ days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- created_
before_ intin_ months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- excluded_
packages Sequence[str] - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- excluded_
properties Mapping[str, Sequence[str]] - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- excluded_
repos Sequence[str] - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- include_
all_ boolprojects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- included_
properties Mapping[str, Sequence[str]] - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- keep_
last_ intn_ versions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- last_
downloaded_ intbefore_ in_ days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- last_
downloaded_ intbefore_ in_ months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
- included
Packages List<String> - Specify a pattern for a package name or an explicit package name on which you want the cleanup policy to run. Only one pattern or explicit name can be entered. To include all packages, use
**
. Example:included_packages = ["**"]
- included
Projects List<String> - Enter the project keys for the projects on which you want the policy to run. To include repositories that are not assigned to any project, enter the project key
default
. Can be empty wheninclude_all_projects
is set totrue
. - package
Types List<String> - repos List<String>
- Specify one or more patterns for the repository name(s) on which you want the cleanup policy to run. You can also specify explicit repository names. Specifying at least one pattern or explicit name is mandatory. Only packages in repositories that match the pattern or explicit name will be deleted. For including all repos use
**
. Example:repos = ["**"]
- created
Before NumberIn Days The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 5 then packages created more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_days
condition to ensure that packages currently in use are not deleted.- created
Before NumberIn Months The cleanup policy will delete packages based on how long ago they were created. For example, if this parameter is 2 then packages created more than 2 months ago will be deleted as part of the policy.
~>JFrog recommends using the
created_before_in_months
condition to ensure that packages currently in use are not deleted.- excluded
Packages List<String> - Specify explicit package names that you want excluded from the policy. Only explicit names (and not patterns) are accepted.
- excluded
Properties Map<List<String>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be excluded from deletion.
- excluded
Repos List<String> - Specify patterns for repository names or explicit repository names that you want excluded from the cleanup policy.
- include
All BooleanProjects Set this value to
true
if you want the policy to run on all Artifactory projects. The default value isfalse
.~>This parameter is relevant only on the global level, for Platform Admins.
- included
Properties Map<List<String>> - A key-value pair applied to the lead artifact of a package. Packages with this property will be deleted.
- keep
Last NumberNVersions Set a value for the number of latest versions to keep. The cleanup policy will remove all versions prior to the number you select here. The latest version is always excluded.
~>Not all package types support this condition. For information on which package types support this condition, learn more.
- last
Downloaded NumberBefore In Days The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 days ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_days
condition to ensure that packages currently in use are not deleted.- last
Downloaded NumberBefore In Months The cleanup policy will delete packages based on how long ago they were downloaded. For example, if this parameter is 5 then packages downloaded more than 5 months ago will be deleted as part of the policy.
~>JFrog recommends using the
last_downloaded_before_in_months
condition to ensure that packages currently in use are not deleted.
Package Details
- Repository
- artifactory pulumi/pulumi-artifactory
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
artifactory
Terraform Provider.