security

package
v2.15.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 11, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceAuthorization deprecated

type ResourceAuthorization struct {
	pulumi.CustomResourceState

	// Set to true to allow public access in the project. Type: boolean.
	Authorized pulumi.BoolOutput `pulumi:"authorized"`
	// The ID of the build definition to authorize. Type: string.
	DefinitionId pulumi.IntPtrOutput `pulumi:"definitionId"`
	// The project ID or project name. Type: string.
	ProjectId pulumi.StringOutput `pulumi:"projectId"`
	// The ID of the resource to authorize. Type: string.
	ResourceId pulumi.StringOutput `pulumi:"resourceId"`
	// The type of the resource to authorize. Type: string. Valid values: `endpoint`, `queue`, `variablegroup`. Default value: `endpoint`.
	Type pulumi.StringPtrOutput `pulumi:"type"`
}

Manages authorization of resources, e.g. for access in build pipelines.

Currently supported resources: service endpoint (aka service connection, endpoint).

## Example Usage

<!--Start PulumiCodeChooser --> ```go package main

import (

"github.com/pulumi/pulumi-azuredevops/sdk/v2/go/azuredevops"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleProject, err := azuredevops.NewProject(ctx, "exampleProject", &azuredevops.ProjectArgs{
			Visibility:       pulumi.String("private"),
			VersionControl:   pulumi.String("Git"),
			WorkItemTemplate: pulumi.String("Agile"),
			Description:      pulumi.String("Managed by Terraform"),
		})
		if err != nil {
			return err
		}
		exampleServiceEndpointBitBucket, err := azuredevops.NewServiceEndpointBitBucket(ctx, "exampleServiceEndpointBitBucket", &azuredevops.ServiceEndpointBitBucketArgs{
			ProjectId:           exampleProject.ID(),
			Username:            pulumi.String("username"),
			Password:            pulumi.String("password"),
			ServiceEndpointName: pulumi.String("example-bitbucket"),
			Description:         pulumi.String("Managed by Terraform"),
		})
		if err != nil {
			return err
		}
		_, err = azuredevops.NewResourceAuthorization(ctx, "exampleResourceAuthorization", &azuredevops.ResourceAuthorizationArgs{
			ProjectId:  exampleProject.ID(),
			ResourceId: exampleServiceEndpointBitBucket.ID(),
			Authorized: pulumi.Bool(true),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

``` <!--End PulumiCodeChooser -->

## Relevant Links

- [Azure DevOps Service REST API 7.0 - Authorize Definition Resource](<https://docs.microsoft.com/en-us/rest/api/azure/devops/build/resources/authorize%!d(MISSING)efinition%!r(MISSING)esources?view=azure-devops-rest-7.0>)

Deprecated: azuredevops.security/resourceauthorization.ResourceAuthorization has been deprecated in favor of azuredevops.index/resourceauthorization.ResourceAuthorization

func GetResourceAuthorization

func GetResourceAuthorization(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *ResourceAuthorizationState, opts ...pulumi.ResourceOption) (*ResourceAuthorization, error)

GetResourceAuthorization gets an existing ResourceAuthorization resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).

func NewResourceAuthorization

func NewResourceAuthorization(ctx *pulumi.Context,
	name string, args *ResourceAuthorizationArgs, opts ...pulumi.ResourceOption) (*ResourceAuthorization, error)

NewResourceAuthorization registers a new resource with the given unique name, arguments, and options.

func (*ResourceAuthorization) ElementType

func (*ResourceAuthorization) ElementType() reflect.Type

func (*ResourceAuthorization) ToResourceAuthorizationOutput

func (i *ResourceAuthorization) ToResourceAuthorizationOutput() ResourceAuthorizationOutput

func (*ResourceAuthorization) ToResourceAuthorizationOutputWithContext

func (i *ResourceAuthorization) ToResourceAuthorizationOutputWithContext(ctx context.Context) ResourceAuthorizationOutput

type ResourceAuthorizationArgs

type ResourceAuthorizationArgs struct {
	// Set to true to allow public access in the project. Type: boolean.
	Authorized pulumi.BoolInput
	// The ID of the build definition to authorize. Type: string.
	DefinitionId pulumi.IntPtrInput
	// The project ID or project name. Type: string.
	ProjectId pulumi.StringInput
	// The ID of the resource to authorize. Type: string.
	ResourceId pulumi.StringInput
	// The type of the resource to authorize. Type: string. Valid values: `endpoint`, `queue`, `variablegroup`. Default value: `endpoint`.
	Type pulumi.StringPtrInput
}

The set of arguments for constructing a ResourceAuthorization resource.

func (ResourceAuthorizationArgs) ElementType

func (ResourceAuthorizationArgs) ElementType() reflect.Type

type ResourceAuthorizationArray

type ResourceAuthorizationArray []ResourceAuthorizationInput

func (ResourceAuthorizationArray) ElementType

func (ResourceAuthorizationArray) ElementType() reflect.Type

func (ResourceAuthorizationArray) ToResourceAuthorizationArrayOutput

func (i ResourceAuthorizationArray) ToResourceAuthorizationArrayOutput() ResourceAuthorizationArrayOutput

func (ResourceAuthorizationArray) ToResourceAuthorizationArrayOutputWithContext

func (i ResourceAuthorizationArray) ToResourceAuthorizationArrayOutputWithContext(ctx context.Context) ResourceAuthorizationArrayOutput

type ResourceAuthorizationArrayInput

type ResourceAuthorizationArrayInput interface {
	pulumi.Input

	ToResourceAuthorizationArrayOutput() ResourceAuthorizationArrayOutput
	ToResourceAuthorizationArrayOutputWithContext(context.Context) ResourceAuthorizationArrayOutput
}

ResourceAuthorizationArrayInput is an input type that accepts ResourceAuthorizationArray and ResourceAuthorizationArrayOutput values. You can construct a concrete instance of `ResourceAuthorizationArrayInput` via:

ResourceAuthorizationArray{ ResourceAuthorizationArgs{...} }

type ResourceAuthorizationArrayOutput

type ResourceAuthorizationArrayOutput struct{ *pulumi.OutputState }

func (ResourceAuthorizationArrayOutput) ElementType

func (ResourceAuthorizationArrayOutput) Index

func (ResourceAuthorizationArrayOutput) ToResourceAuthorizationArrayOutput

func (o ResourceAuthorizationArrayOutput) ToResourceAuthorizationArrayOutput() ResourceAuthorizationArrayOutput

func (ResourceAuthorizationArrayOutput) ToResourceAuthorizationArrayOutputWithContext

func (o ResourceAuthorizationArrayOutput) ToResourceAuthorizationArrayOutputWithContext(ctx context.Context) ResourceAuthorizationArrayOutput

type ResourceAuthorizationInput

type ResourceAuthorizationInput interface {
	pulumi.Input

	ToResourceAuthorizationOutput() ResourceAuthorizationOutput
	ToResourceAuthorizationOutputWithContext(ctx context.Context) ResourceAuthorizationOutput
}

type ResourceAuthorizationMap

type ResourceAuthorizationMap map[string]ResourceAuthorizationInput

func (ResourceAuthorizationMap) ElementType

func (ResourceAuthorizationMap) ElementType() reflect.Type

func (ResourceAuthorizationMap) ToResourceAuthorizationMapOutput

func (i ResourceAuthorizationMap) ToResourceAuthorizationMapOutput() ResourceAuthorizationMapOutput

func (ResourceAuthorizationMap) ToResourceAuthorizationMapOutputWithContext

func (i ResourceAuthorizationMap) ToResourceAuthorizationMapOutputWithContext(ctx context.Context) ResourceAuthorizationMapOutput

type ResourceAuthorizationMapInput

type ResourceAuthorizationMapInput interface {
	pulumi.Input

	ToResourceAuthorizationMapOutput() ResourceAuthorizationMapOutput
	ToResourceAuthorizationMapOutputWithContext(context.Context) ResourceAuthorizationMapOutput
}

ResourceAuthorizationMapInput is an input type that accepts ResourceAuthorizationMap and ResourceAuthorizationMapOutput values. You can construct a concrete instance of `ResourceAuthorizationMapInput` via:

ResourceAuthorizationMap{ "key": ResourceAuthorizationArgs{...} }

type ResourceAuthorizationMapOutput

type ResourceAuthorizationMapOutput struct{ *pulumi.OutputState }

func (ResourceAuthorizationMapOutput) ElementType

func (ResourceAuthorizationMapOutput) MapIndex

func (ResourceAuthorizationMapOutput) ToResourceAuthorizationMapOutput

func (o ResourceAuthorizationMapOutput) ToResourceAuthorizationMapOutput() ResourceAuthorizationMapOutput

func (ResourceAuthorizationMapOutput) ToResourceAuthorizationMapOutputWithContext

func (o ResourceAuthorizationMapOutput) ToResourceAuthorizationMapOutputWithContext(ctx context.Context) ResourceAuthorizationMapOutput

type ResourceAuthorizationOutput

type ResourceAuthorizationOutput struct{ *pulumi.OutputState }

func (ResourceAuthorizationOutput) Authorized added in v2.5.0

Set to true to allow public access in the project. Type: boolean.

func (ResourceAuthorizationOutput) DefinitionId added in v2.5.0

The ID of the build definition to authorize. Type: string.

func (ResourceAuthorizationOutput) ElementType

func (ResourceAuthorizationOutput) ProjectId added in v2.5.0

The project ID or project name. Type: string.

func (ResourceAuthorizationOutput) ResourceId added in v2.5.0

The ID of the resource to authorize. Type: string.

func (ResourceAuthorizationOutput) ToResourceAuthorizationOutput

func (o ResourceAuthorizationOutput) ToResourceAuthorizationOutput() ResourceAuthorizationOutput

func (ResourceAuthorizationOutput) ToResourceAuthorizationOutputWithContext

func (o ResourceAuthorizationOutput) ToResourceAuthorizationOutputWithContext(ctx context.Context) ResourceAuthorizationOutput

func (ResourceAuthorizationOutput) Type added in v2.5.0

The type of the resource to authorize. Type: string. Valid values: `endpoint`, `queue`, `variablegroup`. Default value: `endpoint`.

type ResourceAuthorizationState

type ResourceAuthorizationState struct {
	// Set to true to allow public access in the project. Type: boolean.
	Authorized pulumi.BoolPtrInput
	// The ID of the build definition to authorize. Type: string.
	DefinitionId pulumi.IntPtrInput
	// The project ID or project name. Type: string.
	ProjectId pulumi.StringPtrInput
	// The ID of the resource to authorize. Type: string.
	ResourceId pulumi.StringPtrInput
	// The type of the resource to authorize. Type: string. Valid values: `endpoint`, `queue`, `variablegroup`. Default value: `endpoint`.
	Type pulumi.StringPtrInput
}

func (ResourceAuthorizationState) ElementType

func (ResourceAuthorizationState) ElementType() reflect.Type

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL