1. Packages
  2. Harbor
  3. API Docs
  4. ConfigSecurity
Harbor v3.10.15 published on Saturday, Sep 28, 2024 by Pulumiverse

harbor.ConfigSecurity

Explore with Pulumi AI

harbor logo
Harbor v3.10.15 published on Saturday, Sep 28, 2024 by Pulumiverse

    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

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The ConfigSecurity resource accepts the following input properties:

    CveAllowlists 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"]
    ExpiresAt 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.
    CveAllowlists []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"]
    ExpiresAt 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.
    cveAllowlists 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"]
    expiresAt 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.
    cveAllowlists 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"]
    expiresAt 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.
    cveAllowlists 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"]
    expiresAt 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:

    CreationTime string
    Time of creation of the list.
    Id string
    The provider-assigned unique ID for this managed resource.
    UpdateTime string
    Time of update of the list.
    CreationTime string
    Time of creation of the list.
    Id string
    The provider-assigned unique ID for this managed resource.
    UpdateTime string
    Time of update of the list.
    creationTime String
    Time of creation of the list.
    id String
    The provider-assigned unique ID for this managed resource.
    updateTime String
    Time of update of the list.
    creationTime string
    Time of creation of the list.
    id string
    The provider-assigned unique ID for this managed resource.
    updateTime 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.
    creationTime String
    Time of creation of the list.
    id String
    The provider-assigned unique ID for this managed resource.
    updateTime 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.
    The following state arguments are supported:
    CreationTime string
    Time of creation of the list.
    CveAllowlists 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"]
    ExpiresAt 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.
    UpdateTime string
    Time of update of the list.
    CreationTime string
    Time of creation of the list.
    CveAllowlists []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"]
    ExpiresAt 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.
    UpdateTime string
    Time of update of the list.
    creationTime String
    Time of creation of the list.
    cveAllowlists 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"]
    expiresAt 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.
    updateTime String
    Time of update of the list.
    creationTime string
    Time of creation of the list.
    cveAllowlists 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"]
    expiresAt 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.
    updateTime 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.
    creationTime String
    Time of creation of the list.
    cveAllowlists 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"]
    expiresAt 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.
    updateTime 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.
    harbor logo
    Harbor v3.10.15 published on Saturday, Sep 28, 2024 by Pulumiverse