@pulumi/harness
Version:
A Pulumi package for creating and managing Harness resources.
191 lines (190 loc) • 5.28 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* Data source for retrieving a Harness policyset.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as harness from "@pulumi/harness";
*
* const test = harness.platform.getPolicySet({
* identifier: "harness_platform_policyset.test.identifier",
* name: "harness_platform_policyset.test.name",
* action: "onrun",
* type: "pipeline",
* enabled: true,
* policyReferences: [{
* identifier: "always_run",
* severity: "warning",
* }],
* });
* ```
*/
export declare function getPolicySet(args: GetPolicySetArgs, opts?: pulumi.InvokeOptions): Promise<GetPolicySetResult>;
/**
* A collection of arguments for invoking getPolicySet.
*/
export interface GetPolicySetArgs {
/**
* Action code for the policyset.
*/
action: string;
/**
* Enabled for the policyset.
*/
enabled?: boolean;
/**
* Unique identifier of the resource.
*/
identifier: string;
/**
* Name of the resource.
*/
name?: string;
/**
* Unique identifier of the organization.
*/
orgId?: string;
/**
* List of policy identifiers / severity for the policyset. Deprecated: Use 'policy_references' instead.
*
* @deprecated Use 'policy_references' instead. This field will be removed in a future version.
*/
policies?: inputs.platform.GetPolicySetPolicy[];
/**
* Set of policy identifiers / severity for the policyset. Order is not significant.
*/
policyReferences?: inputs.platform.GetPolicySetPolicyReference[];
/**
* Unique identifier of the project.
*/
projectId?: string;
/**
* Type of the policyset.
*/
type: string;
}
/**
* A collection of values returned by getPolicySet.
*/
export interface GetPolicySetResult {
/**
* Action code for the policyset.
*/
readonly action: string;
/**
* Description of the resource.
*/
readonly description: string;
/**
* Enabled for the policyset.
*/
readonly enabled?: boolean;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
/**
* Unique identifier of the resource.
*/
readonly identifier: string;
/**
* Name of the resource.
*/
readonly name?: string;
/**
* Unique identifier of the organization.
*/
readonly orgId?: string;
/**
* List of policy identifiers / severity for the policyset. Deprecated: Use 'policy_references' instead.
*
* @deprecated Use 'policy_references' instead. This field will be removed in a future version.
*/
readonly policies: outputs.platform.GetPolicySetPolicy[];
/**
* Set of policy identifiers / severity for the policyset. Order is not significant.
*/
readonly policyReferences: outputs.platform.GetPolicySetPolicyReference[];
/**
* Unique identifier of the project.
*/
readonly projectId?: string;
/**
* Tags to associate with the resource.
*/
readonly tags: string[];
/**
* Type of the policyset.
*/
readonly type: string;
}
/**
* Data source for retrieving a Harness policyset.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as harness from "@pulumi/harness";
*
* const test = harness.platform.getPolicySet({
* identifier: "harness_platform_policyset.test.identifier",
* name: "harness_platform_policyset.test.name",
* action: "onrun",
* type: "pipeline",
* enabled: true,
* policyReferences: [{
* identifier: "always_run",
* severity: "warning",
* }],
* });
* ```
*/
export declare function getPolicySetOutput(args: GetPolicySetOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetPolicySetResult>;
/**
* A collection of arguments for invoking getPolicySet.
*/
export interface GetPolicySetOutputArgs {
/**
* Action code for the policyset.
*/
action: pulumi.Input<string>;
/**
* Enabled for the policyset.
*/
enabled?: pulumi.Input<boolean>;
/**
* Unique identifier of the resource.
*/
identifier: pulumi.Input<string>;
/**
* Name of the resource.
*/
name?: pulumi.Input<string>;
/**
* Unique identifier of the organization.
*/
orgId?: pulumi.Input<string>;
/**
* List of policy identifiers / severity for the policyset. Deprecated: Use 'policy_references' instead.
*
* @deprecated Use 'policy_references' instead. This field will be removed in a future version.
*/
policies?: pulumi.Input<pulumi.Input<inputs.platform.GetPolicySetPolicyArgs>[]>;
/**
* Set of policy identifiers / severity for the policyset. Order is not significant.
*/
policyReferences?: pulumi.Input<pulumi.Input<inputs.platform.GetPolicySetPolicyReferenceArgs>[]>;
/**
* Unique identifier of the project.
*/
projectId?: pulumi.Input<string>;
/**
* Type of the policyset.
*/
type: pulumi.Input<string>;
}