harbor.ConfigSecurity
Explore with Pulumi AI
Example Usage
resource "harbor_config_security" "main" {
cve_allowlist = ["CVE-456", "CVE-123"]
expires_at = "1701167767"
}
Create ConfigSecurity Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ConfigSecurity(name: string, args: ConfigSecurityArgs, opts?: CustomResourceOptions);
@overload
def ConfigSecurity(resource_name: str,
args: ConfigSecurityArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ConfigSecurity(resource_name: str,
opts: Optional[ResourceOptions] = None,
cve_allowlists: Optional[Sequence[str]] = None,
expires_at: Optional[int] = None)
func NewConfigSecurity(ctx *Context, name string, args ConfigSecurityArgs, opts ...ResourceOption) (*ConfigSecurity, error)
public ConfigSecurity(string name, ConfigSecurityArgs args, CustomResourceOptions? opts = null)
public ConfigSecurity(String name, ConfigSecurityArgs args)
public ConfigSecurity(String name, ConfigSecurityArgs args, CustomResourceOptions options)
type: harbor:ConfigSecurity
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 ConfigSecurityArgs
- 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 ConfigSecurityArgs
- 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 ConfigSecurityArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ConfigSecurityArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ConfigSecurityArgs
- 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 configSecurityResource = new Harbor.ConfigSecurity("configSecurityResource", new()
{
CveAllowlists = new[]
{
"string",
},
ExpiresAt = 0,
});
example, err := harbor.NewConfigSecurity(ctx, "configSecurityResource", &harbor.ConfigSecurityArgs{
CveAllowlists: pulumi.StringArray{
pulumi.String("string"),
},
ExpiresAt: pulumi.Int(0),
})
var configSecurityResource = new ConfigSecurity("configSecurityResource", ConfigSecurityArgs.builder()
.cveAllowlists("string")
.expiresAt(0)
.build());
config_security_resource = harbor.ConfigSecurity("configSecurityResource",
cve_allowlists=["string"],
expires_at=0)
const configSecurityResource = new harbor.ConfigSecurity("configSecurityResource", {
cveAllowlists: ["string"],
expiresAt: 0,
});
type: harbor:ConfigSecurity
properties:
cveAllowlists:
- string
expiresAt: 0
ConfigSecurity Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The ConfigSecurity resource accepts the following input properties:
- Cve
Allowlists List<string> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- Expires
At int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- Cve
Allowlists []string - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- Expires
At int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- cve
Allowlists List<String> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At Integer - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- cve
Allowlists string[] - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At number - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- cve_
allowlists Sequence[str] - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires_
at int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- cve
Allowlists List<String> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At Number - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
Outputs
All input properties are implicitly available as output properties. Additionally, the ConfigSecurity resource produces the following output properties:
- Creation
Time string - Time of creation of the list.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - Time of update of the list.
- Creation
Time string - Time of creation of the list.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - Time of update of the list.
- creation
Time String - Time of creation of the list.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - Time of update of the list.
- creation
Time string - Time of creation of the list.
- id string
- The provider-assigned unique ID for this managed resource.
- update
Time string - Time of update of the list.
- creation_
time str - Time of creation of the list.
- id str
- The provider-assigned unique ID for this managed resource.
- update_
time str - Time of update of the list.
- creation
Time String - Time of creation of the list.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - Time of update of the list.
Look up Existing ConfigSecurity Resource
Get an existing ConfigSecurity 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?: ConfigSecurityState, opts?: CustomResourceOptions): ConfigSecurity
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
creation_time: Optional[str] = None,
cve_allowlists: Optional[Sequence[str]] = None,
expires_at: Optional[int] = None,
update_time: Optional[str] = None) -> ConfigSecurity
func GetConfigSecurity(ctx *Context, name string, id IDInput, state *ConfigSecurityState, opts ...ResourceOption) (*ConfigSecurity, error)
public static ConfigSecurity Get(string name, Input<string> id, ConfigSecurityState? state, CustomResourceOptions? opts = null)
public static ConfigSecurity get(String name, Output<String> id, ConfigSecurityState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- 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.
- Creation
Time string - Time of creation of the list.
- Cve
Allowlists List<string> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- Expires
At int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- Update
Time string - Time of update of the list.
- Creation
Time string - Time of creation of the list.
- Cve
Allowlists []string - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- Expires
At int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- Update
Time string - Time of update of the list.
- creation
Time String - Time of creation of the list.
- cve
Allowlists List<String> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At Integer - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- update
Time String - Time of update of the list.
- creation
Time string - Time of creation of the list.
- cve
Allowlists string[] - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At number - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- update
Time string - Time of update of the list.
- creation_
time str - Time of creation of the list.
- cve_
allowlists Sequence[str] - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires_
at int - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- update_
time str - Time of update of the list.
- creation
Time String - Time of creation of the list.
- cve
Allowlists List<String> - System allowlist. Vulnerabilities in this list will be ignored when pushing and pulling images. Should be in the format or
["CVE-123", "CVE-145"]
or["CVE-123"]
- expires
At Number - The time for expiration of the allowlist, in the form of seconds since epoch. This is an optional attribute, if it's not set the CVE allowlist does not expire.
- update
Time String - Time of update of the list.
Import
import using the id of the repo
$ pulumi import harbor:index/configSecurity:ConfigSecurity main "7"
Note that at this point of time Harbor doesn’t has any api endpoint for deleting this list. Only updating the records.
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- harbor pulumiverse/pulumi-harbor
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
harbor
Terraform Provider.