Harbor v3.9.1 published on Tuesday, May 30, 2023 by Pulumiverse
harbor.ProjectMemberGroup
Explore with Pulumi AI
Import
Harbor project member group can be imported using the project id
and member id
eg, `
$ pulumi import harbor:index/projectMemberGroup:ProjectMemberGroup main /projects/10/members/200
`
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Harbor = Pulumiverse.Harbor;
return await Deployment.RunAsync(() =>
{
var mainProject = new Harbor.Project("mainProject");
var mainProjectMemberGroup = new Harbor.ProjectMemberGroup("mainProjectMemberGroup", new()
{
ProjectId = mainProject.Id,
GroupName = "testing1",
Role = "projectadmin",
Type = "oidc",
});
});
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-harbor/sdk/v3/go/harbor"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
mainProject, err := harbor.NewProject(ctx, "mainProject", nil)
if err != nil {
return err
}
_, err = harbor.NewProjectMemberGroup(ctx, "mainProjectMemberGroup", &harbor.ProjectMemberGroupArgs{
ProjectId: mainProject.ID(),
GroupName: pulumi.String("testing1"),
Role: pulumi.String("projectadmin"),
Type: pulumi.String("oidc"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.harbor.Project;
import com.pulumi.harbor.ProjectMemberGroup;
import com.pulumi.harbor.ProjectMemberGroupArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var mainProject = new Project("mainProject");
var mainProjectMemberGroup = new ProjectMemberGroup("mainProjectMemberGroup", ProjectMemberGroupArgs.builder()
.projectId(mainProject.id())
.groupName("testing1")
.role("projectadmin")
.type("oidc")
.build());
}
}
import pulumi
import pulumiverse_harbor as harbor
main_project = harbor.Project("mainProject")
main_project_member_group = harbor.ProjectMemberGroup("mainProjectMemberGroup",
project_id=main_project.id,
group_name="testing1",
role="projectadmin",
type="oidc")
import * as pulumi from "@pulumi/pulumi";
import * as harbor from "@pulumiverse/harbor";
const mainProject = new harbor.Project("mainProject", {});
const mainProjectMemberGroup = new harbor.ProjectMemberGroup("mainProjectMemberGroup", {
projectId: mainProject.id,
groupName: "testing1",
role: "projectadmin",
type: "oidc",
});
resources:
mainProject:
type: harbor:Project
mainProjectMemberGroup:
type: harbor:ProjectMemberGroup
properties:
projectId: ${mainProject.id}
groupName: testing1
role: projectadmin
type: oidc
Create ProjectMemberGroup Resource
new ProjectMemberGroup(name: string, args: ProjectMemberGroupArgs, opts?: CustomResourceOptions);
@overload
def ProjectMemberGroup(resource_name: str,
opts: Optional[ResourceOptions] = None,
group_id: Optional[int] = None,
group_name: Optional[str] = None,
ldap_group_dn: Optional[str] = None,
project_id: Optional[str] = None,
role: Optional[str] = None,
type: Optional[str] = None)
@overload
def ProjectMemberGroup(resource_name: str,
args: ProjectMemberGroupArgs,
opts: Optional[ResourceOptions] = None)
func NewProjectMemberGroup(ctx *Context, name string, args ProjectMemberGroupArgs, opts ...ResourceOption) (*ProjectMemberGroup, error)
public ProjectMemberGroup(string name, ProjectMemberGroupArgs args, CustomResourceOptions? opts = null)
public ProjectMemberGroup(String name, ProjectMemberGroupArgs args)
public ProjectMemberGroup(String name, ProjectMemberGroupArgs args, CustomResourceOptions options)
type: harbor:ProjectMemberGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ProjectMemberGroupArgs
- 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 ProjectMemberGroupArgs
- 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 ProjectMemberGroupArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ProjectMemberGroupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ProjectMemberGroupArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
ProjectMemberGroup 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 ProjectMemberGroup resource accepts the following input properties:
- project_
id str - role str
- type str
- group_
id int - group_
name str - ldap_
group_ strdn
Outputs
All input properties are implicitly available as output properties. Additionally, the ProjectMemberGroup resource produces the following output properties:
Look up Existing ProjectMemberGroup Resource
Get an existing ProjectMemberGroup 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?: ProjectMemberGroupState, opts?: CustomResourceOptions): ProjectMemberGroup
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
group_id: Optional[int] = None,
group_name: Optional[str] = None,
ldap_group_dn: Optional[str] = None,
member_id: Optional[int] = None,
project_id: Optional[str] = None,
role: Optional[str] = None,
type: Optional[str] = None) -> ProjectMemberGroup
func GetProjectMemberGroup(ctx *Context, name string, id IDInput, state *ProjectMemberGroupState, opts ...ResourceOption) (*ProjectMemberGroup, error)
public static ProjectMemberGroup Get(string name, Input<string> id, ProjectMemberGroupState? state, CustomResourceOptions? opts = null)
public static ProjectMemberGroup get(String name, Output<String> id, ProjectMemberGroupState 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.
- group_
id int - group_
name str - ldap_
group_ strdn - member_
id int - project_
id str - role str
- type str
Package Details
- Repository
- harbor pulumiverse/pulumi-harbor
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
harbor
Terraform Provider.