@pulumi/gcp
Version:
A Pulumi package for creating and managing Google Cloud Platform resources.
487 lines (486 loc) • 18.6 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* The Cloud Deploy `DeliveryPipeline` resource
*
* ## Example Usage
*
* ### Canary_delivery_pipeline
* Creates a basic Cloud Deploy delivery pipeline
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const primary = new gcp.clouddeploy.DeliveryPipeline("primary", {
* location: "us-west1",
* name: "pipeline",
* description: "basic description",
* project: "my-project-name",
* serialPipeline: {
* stages: [
* {
* deployParameters: [{
* values: {
* deployParameterKey: "deployParameterValue",
* },
* matchTargetLabels: {},
* }],
* profiles: [
* "example-profile-one",
* "example-profile-two",
* ],
* targetId: "example-target-one",
* },
* {
* profiles: [],
* targetId: "example-target-two",
* },
* ],
* },
* annotations: {
* my_first_annotation: "example-annotation-1",
* my_second_annotation: "example-annotation-2",
* },
* labels: {
* my_first_label: "example-label-1",
* my_second_label: "example-label-2",
* },
* });
* ```
* ### Canary_service_networking_delivery_pipeline
* Creates a basic Cloud Deploy delivery pipeline
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const primary = new gcp.clouddeploy.DeliveryPipeline("primary", {
* location: "us-west1",
* name: "pipeline",
* description: "basic description",
* project: "my-project-name",
* serialPipeline: {
* stages: [
* {
* deployParameters: [{
* values: {
* deployParameterKey: "deployParameterValue",
* },
* matchTargetLabels: {},
* }],
* profiles: [
* "example-profile-one",
* "example-profile-two",
* ],
* targetId: "example-target-one",
* },
* {
* profiles: [],
* targetId: "example-target-two",
* },
* ],
* },
* annotations: {
* my_first_annotation: "example-annotation-1",
* my_second_annotation: "example-annotation-2",
* },
* labels: {
* my_first_label: "example-label-1",
* my_second_label: "example-label-2",
* },
* });
* ```
* ### Canaryrun_delivery_pipeline
* Creates a basic Cloud Deploy delivery pipeline
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const primary = new gcp.clouddeploy.DeliveryPipeline("primary", {
* location: "us-west1",
* name: "pipeline",
* description: "basic description",
* project: "my-project-name",
* serialPipeline: {
* stages: [
* {
* deployParameters: [{
* values: {
* deployParameterKey: "deployParameterValue",
* },
* matchTargetLabels: {},
* }],
* profiles: [
* "example-profile-one",
* "example-profile-two",
* ],
* targetId: "example-target-one",
* },
* {
* profiles: [],
* targetId: "example-target-two",
* },
* ],
* },
* annotations: {
* my_first_annotation: "example-annotation-1",
* my_second_annotation: "example-annotation-2",
* },
* labels: {
* my_first_label: "example-label-1",
* my_second_label: "example-label-2",
* },
* });
* ```
* ### Delivery_pipeline
* Creates a basic Cloud Deploy delivery pipeline
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const primary = new gcp.clouddeploy.DeliveryPipeline("primary", {
* location: "us-west1",
* name: "pipeline",
* description: "basic description",
* project: "my-project-name",
* serialPipeline: {
* stages: [
* {
* deployParameters: [{
* values: {
* deployParameterKey: "deployParameterValue",
* },
* matchTargetLabels: {},
* }],
* profiles: [
* "example-profile-one",
* "example-profile-two",
* ],
* targetId: "example-target-one",
* },
* {
* profiles: [],
* targetId: "example-target-two",
* },
* ],
* },
* annotations: {
* my_first_annotation: "example-annotation-1",
* my_second_annotation: "example-annotation-2",
* },
* labels: {
* my_first_label: "example-label-1",
* my_second_label: "example-label-2",
* },
* });
* ```
* ### Verify_delivery_pipeline
* tests creating and updating a delivery pipeline with deployment verification strategy
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
*
* const primary = new gcp.clouddeploy.DeliveryPipeline("primary", {
* location: "us-west1",
* name: "pipeline",
* description: "basic description",
* project: "my-project-name",
* serialPipeline: {
* stages: [
* {
* deployParameters: [{
* values: {
* deployParameterKey: "deployParameterValue",
* },
* matchTargetLabels: {},
* }],
* profiles: [
* "example-profile-one",
* "example-profile-two",
* ],
* targetId: "example-target-one",
* },
* {
* profiles: [],
* targetId: "example-target-two",
* },
* ],
* },
* annotations: {
* my_first_annotation: "example-annotation-1",
* my_second_annotation: "example-annotation-2",
* },
* labels: {
* my_first_label: "example-label-1",
* my_second_label: "example-label-2",
* },
* });
* ```
*
* ## Import
*
* DeliveryPipeline can be imported using any of these accepted formats:
*
* * `projects/{{project}}/locations/{{location}}/deliveryPipelines/{{name}}`
*
* * `{{project}}/{{location}}/{{name}}`
*
* * `{{location}}/{{name}}`
*
* When using the `pulumi import` command, DeliveryPipeline can be imported using one of the formats above. For example:
*
* ```sh
* $ pulumi import gcp:clouddeploy/deliveryPipeline:DeliveryPipeline default projects/{{project}}/locations/{{location}}/deliveryPipelines/{{name}}
* ```
*
* ```sh
* $ pulumi import gcp:clouddeploy/deliveryPipeline:DeliveryPipeline default {{project}}/{{location}}/{{name}}
* ```
*
* ```sh
* $ pulumi import gcp:clouddeploy/deliveryPipeline:DeliveryPipeline default {{location}}/{{name}}
* ```
*/
export declare class DeliveryPipeline extends pulumi.CustomResource {
/**
* Get an existing DeliveryPipeline resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: DeliveryPipelineState, opts?: pulumi.CustomResourceOptions): DeliveryPipeline;
/**
* Returns true if the given object is an instance of DeliveryPipeline. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is DeliveryPipeline;
/**
* User annotations. These attributes can only be set and used by the user, and not by Google Cloud Deploy. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
*
* **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration.
* Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource.
*/
readonly annotations: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* Output only. Information around the state of the Delivery Pipeline.
*/
readonly conditions: pulumi.Output<outputs.clouddeploy.DeliveryPipelineCondition[]>;
/**
* Output only. Time at which the pipeline was created.
*/
readonly createTime: pulumi.Output<string>;
/**
* Description of the `DeliveryPipeline`. Max length is 255 characters.
*/
readonly description: pulumi.Output<string | undefined>;
readonly effectiveAnnotations: pulumi.Output<{
[key: string]: string;
}>;
/**
* All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
*/
readonly effectiveLabels: pulumi.Output<{
[key: string]: string;
}>;
/**
* This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
*/
readonly etag: pulumi.Output<string>;
/**
* Labels are attributes that can be set and used by both the user and by Google Cloud Deploy. Labels must meet the following constraints: * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. * All characters must use UTF-8 encoding, and international characters are allowed. * Keys must start with a lowercase letter or international character. * Each resource is limited to a maximum of 64 labels. Both keys and values are additionally constrained to be <= 128 bytes.
*
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
readonly labels: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* The location for the resource
*/
readonly location: pulumi.Output<string>;
/**
* Name of the `DeliveryPipeline`. Format is `a-z?`.
*
*
*
* - - -
*/
readonly name: pulumi.Output<string>;
/**
* The project for the resource
*/
readonly project: pulumi.Output<string>;
/**
* The combination of labels configured directly on the resource and default labels configured on the provider.
*/
readonly pulumiLabels: pulumi.Output<{
[key: string]: string;
}>;
/**
* SerialPipeline defines a sequential set of stages for a `DeliveryPipeline`.
*/
readonly serialPipeline: pulumi.Output<outputs.clouddeploy.DeliveryPipelineSerialPipeline | undefined>;
/**
* When suspended, no new releases or rollouts can be created, but in-progress ones will complete.
*/
readonly suspended: pulumi.Output<boolean | undefined>;
/**
* Output only. Unique identifier of the `DeliveryPipeline`.
*/
readonly uid: pulumi.Output<string>;
/**
* Output only. Most recent time at which the pipeline was updated.
*/
readonly updateTime: pulumi.Output<string>;
/**
* Create a DeliveryPipeline resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: DeliveryPipelineArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering DeliveryPipeline resources.
*/
export interface DeliveryPipelineState {
/**
* User annotations. These attributes can only be set and used by the user, and not by Google Cloud Deploy. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
*
* **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration.
* Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource.
*/
annotations?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Output only. Information around the state of the Delivery Pipeline.
*/
conditions?: pulumi.Input<pulumi.Input<inputs.clouddeploy.DeliveryPipelineCondition>[]>;
/**
* Output only. Time at which the pipeline was created.
*/
createTime?: pulumi.Input<string>;
/**
* Description of the `DeliveryPipeline`. Max length is 255 characters.
*/
description?: pulumi.Input<string>;
effectiveAnnotations?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
*/
effectiveLabels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
*/
etag?: pulumi.Input<string>;
/**
* Labels are attributes that can be set and used by both the user and by Google Cloud Deploy. Labels must meet the following constraints: * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. * All characters must use UTF-8 encoding, and international characters are allowed. * Keys must start with a lowercase letter or international character. * Each resource is limited to a maximum of 64 labels. Both keys and values are additionally constrained to be <= 128 bytes.
*
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The location for the resource
*/
location?: pulumi.Input<string>;
/**
* Name of the `DeliveryPipeline`. Format is `a-z?`.
*
*
*
* - - -
*/
name?: pulumi.Input<string>;
/**
* The project for the resource
*/
project?: pulumi.Input<string>;
/**
* The combination of labels configured directly on the resource and default labels configured on the provider.
*/
pulumiLabels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* SerialPipeline defines a sequential set of stages for a `DeliveryPipeline`.
*/
serialPipeline?: pulumi.Input<inputs.clouddeploy.DeliveryPipelineSerialPipeline>;
/**
* When suspended, no new releases or rollouts can be created, but in-progress ones will complete.
*/
suspended?: pulumi.Input<boolean>;
/**
* Output only. Unique identifier of the `DeliveryPipeline`.
*/
uid?: pulumi.Input<string>;
/**
* Output only. Most recent time at which the pipeline was updated.
*/
updateTime?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a DeliveryPipeline resource.
*/
export interface DeliveryPipelineArgs {
/**
* User annotations. These attributes can only be set and used by the user, and not by Google Cloud Deploy. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
*
* **Note**: This field is non-authoritative, and will only manage the annotations present in your configuration.
* Please refer to the field `effectiveAnnotations` for all of the annotations present on the resource.
*/
annotations?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Description of the `DeliveryPipeline`. Max length is 255 characters.
*/
description?: pulumi.Input<string>;
/**
* Labels are attributes that can be set and used by both the user and by Google Cloud Deploy. Labels must meet the following constraints: * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. * All characters must use UTF-8 encoding, and international characters are allowed. * Keys must start with a lowercase letter or international character. * Each resource is limited to a maximum of 64 labels. Both keys and values are additionally constrained to be <= 128 bytes.
*
* **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
* Please refer to the field `effectiveLabels` for all of the labels present on the resource.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* The location for the resource
*/
location: pulumi.Input<string>;
/**
* Name of the `DeliveryPipeline`. Format is `a-z?`.
*
*
*
* - - -
*/
name?: pulumi.Input<string>;
/**
* The project for the resource
*/
project?: pulumi.Input<string>;
/**
* SerialPipeline defines a sequential set of stages for a `DeliveryPipeline`.
*/
serialPipeline?: pulumi.Input<inputs.clouddeploy.DeliveryPipelineSerialPipeline>;
/**
* When suspended, no new releases or rollouts can be created, but in-progress ones will complete.
*/
suspended?: pulumi.Input<boolean>;
}