1. Packages
  2. Harbor
  3. API Docs
  4. ProjectMemberUser
Harbor v3.10.9 published on Friday, Apr 19, 2024 by Pulumiverse

harbor.ProjectMemberUser

Explore with Pulumi AI

harbor logo
Harbor v3.10.9 published on Friday, Apr 19, 2024 by Pulumiverse

    Example Usage

    resource "harbor_project" "main" {
        name = "main"
    }
    
    resource "harbor_project_member_user" "main" {
      project_id    = harbor_project.main.id
      user_name     = "testing1"
      role          = "projectadmin"
    }
    

    Create ProjectMemberUser Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ProjectMemberUser(name: string, args: ProjectMemberUserArgs, opts?: CustomResourceOptions);
    @overload
    def ProjectMemberUser(resource_name: str,
                          args: ProjectMemberUserArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def ProjectMemberUser(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          project_id: Optional[str] = None,
                          role: Optional[str] = None,
                          user_name: Optional[str] = None)
    func NewProjectMemberUser(ctx *Context, name string, args ProjectMemberUserArgs, opts ...ResourceOption) (*ProjectMemberUser, error)
    public ProjectMemberUser(string name, ProjectMemberUserArgs args, CustomResourceOptions? opts = null)
    public ProjectMemberUser(String name, ProjectMemberUserArgs args)
    public ProjectMemberUser(String name, ProjectMemberUserArgs args, CustomResourceOptions options)
    
    type: harbor:ProjectMemberUser
    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 ProjectMemberUserArgs
    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 ProjectMemberUserArgs
    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 ProjectMemberUserArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ProjectMemberUserArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ProjectMemberUserArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var projectMemberUserResource = new Harbor.ProjectMemberUser("projectMemberUserResource", new()
    {
        ProjectId = "string",
        Role = "string",
        UserName = "string",
    });
    
    example, err := harbor.NewProjectMemberUser(ctx, "projectMemberUserResource", &harbor.ProjectMemberUserArgs{
    	ProjectId: pulumi.String("string"),
    	Role:      pulumi.String("string"),
    	UserName:  pulumi.String("string"),
    })
    
    var projectMemberUserResource = new ProjectMemberUser("projectMemberUserResource", ProjectMemberUserArgs.builder()        
        .projectId("string")
        .role("string")
        .userName("string")
        .build());
    
    project_member_user_resource = harbor.ProjectMemberUser("projectMemberUserResource",
        project_id="string",
        role="string",
        user_name="string")
    
    const projectMemberUserResource = new harbor.ProjectMemberUser("projectMemberUserResource", {
        projectId: "string",
        role: "string",
        userName: "string",
    });
    
    type: harbor:ProjectMemberUser
    properties:
        projectId: string
        role: string
        userName: string
    

    ProjectMemberUser 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 ProjectMemberUser resource accepts the following input properties:

    ProjectId string
    The project id of the project that the entity will have access to.
    Role string
    The permissions that the entity will be granted.
    UserName string
    The name of the member entity.
    ProjectId string
    The project id of the project that the entity will have access to.
    Role string
    The permissions that the entity will be granted.
    UserName string
    The name of the member entity.
    projectId String
    The project id of the project that the entity will have access to.
    role String
    The permissions that the entity will be granted.
    userName String
    The name of the member entity.
    projectId string
    The project id of the project that the entity will have access to.
    role string
    The permissions that the entity will be granted.
    userName string
    The name of the member entity.
    project_id str
    The project id of the project that the entity will have access to.
    role str
    The permissions that the entity will be granted.
    user_name str
    The name of the member entity.
    projectId String
    The project id of the project that the entity will have access to.
    role String
    The permissions that the entity will be granted.
    userName String
    The name of the member entity.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ProjectMemberUser resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    MemberId int
    The member id of the member.
    Id string
    The provider-assigned unique ID for this managed resource.
    MemberId int
    The member id of the member.
    id String
    The provider-assigned unique ID for this managed resource.
    memberId Integer
    The member id of the member.
    id string
    The provider-assigned unique ID for this managed resource.
    memberId number
    The member id of the member.
    id str
    The provider-assigned unique ID for this managed resource.
    member_id int
    The member id of the member.
    id String
    The provider-assigned unique ID for this managed resource.
    memberId Number
    The member id of the member.

    Look up Existing ProjectMemberUser Resource

    Get an existing ProjectMemberUser 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?: ProjectMemberUserState, opts?: CustomResourceOptions): ProjectMemberUser
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            member_id: Optional[int] = None,
            project_id: Optional[str] = None,
            role: Optional[str] = None,
            user_name: Optional[str] = None) -> ProjectMemberUser
    func GetProjectMemberUser(ctx *Context, name string, id IDInput, state *ProjectMemberUserState, opts ...ResourceOption) (*ProjectMemberUser, error)
    public static ProjectMemberUser Get(string name, Input<string> id, ProjectMemberUserState? state, CustomResourceOptions? opts = null)
    public static ProjectMemberUser get(String name, Output<String> id, ProjectMemberUserState 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:
    MemberId int
    The member id of the member.
    ProjectId string
    The project id of the project that the entity will have access to.
    Role string
    The permissions that the entity will be granted.
    UserName string
    The name of the member entity.
    MemberId int
    The member id of the member.
    ProjectId string
    The project id of the project that the entity will have access to.
    Role string
    The permissions that the entity will be granted.
    UserName string
    The name of the member entity.
    memberId Integer
    The member id of the member.
    projectId String
    The project id of the project that the entity will have access to.
    role String
    The permissions that the entity will be granted.
    userName String
    The name of the member entity.
    memberId number
    The member id of the member.
    projectId string
    The project id of the project that the entity will have access to.
    role string
    The permissions that the entity will be granted.
    userName string
    The name of the member entity.
    member_id int
    The member id of the member.
    project_id str
    The project id of the project that the entity will have access to.
    role str
    The permissions that the entity will be granted.
    user_name str
    The name of the member entity.
    memberId Number
    The member id of the member.
    projectId String
    The project id of the project that the entity will have access to.
    role String
    The permissions that the entity will be granted.
    userName String
    The name of the member entity.

    Import

    $ pulumi import harbor:index/projectMemberUser:ProjectMemberUser main /projects/10/members/200
    

    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.9 published on Friday, Apr 19, 2024 by Pulumiverse