@pulumiverse/buildkite 2.3.1 → 3.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. package/README.md +5 -0
  2. package/agent/agentToken.d.ts +13 -19
  3. package/agent/agentToken.js +6 -6
  4. package/agent/agentToken.js.map +1 -1
  5. package/cluster/cluster.d.ts +76 -20
  6. package/cluster/cluster.js +56 -6
  7. package/cluster/cluster.js.map +1 -1
  8. package/cluster/clusterAgentToken.d.ts +51 -15
  9. package/cluster/clusterAgentToken.js +28 -8
  10. package/cluster/clusterAgentToken.js.map +1 -1
  11. package/cluster/clusterDefaultQueue.d.ts +132 -0
  12. package/cluster/clusterDefaultQueue.js +123 -0
  13. package/cluster/clusterDefaultQueue.js.map +1 -0
  14. package/cluster/clusterQueue.d.ts +44 -50
  15. package/cluster/clusterQueue.js +37 -43
  16. package/cluster/clusterQueue.js.map +1 -1
  17. package/cluster/getCluster.d.ts +52 -5
  18. package/cluster/getCluster.js +44 -0
  19. package/cluster/getCluster.js.map +1 -1
  20. package/cluster/index.d.ts +3 -0
  21. package/cluster/index.js +6 -1
  22. package/cluster/index.js.map +1 -1
  23. package/config/vars.d.ts +9 -7
  24. package/config/vars.js +6 -0
  25. package/config/vars.js.map +1 -1
  26. package/getMeta.d.ts +55 -1
  27. package/getMeta.js +55 -1
  28. package/getMeta.js.map +1 -1
  29. package/index.d.ts +1 -0
  30. package/index.js +3 -2
  31. package/index.js.map +1 -1
  32. package/organization/banner.d.ts +106 -0
  33. package/organization/banner.js +104 -0
  34. package/organization/banner.js.map +1 -0
  35. package/organization/getOrganization.d.ts +12 -21
  36. package/organization/getOrganization.js +9 -21
  37. package/organization/getOrganization.js.map +1 -1
  38. package/organization/index.d.ts +4 -3
  39. package/organization/index.js +8 -7
  40. package/organization/index.js.map +1 -1
  41. package/organization/organization.d.ts +31 -13
  42. package/organization/organization.js +12 -10
  43. package/organization/organization.js.map +1 -1
  44. package/package.json +2 -3
  45. package/package.json.bak +1 -2
  46. package/pipeline/getPipeline.d.ts +26 -18
  47. package/pipeline/getPipeline.js +12 -14
  48. package/pipeline/getPipeline.js.map +1 -1
  49. package/pipeline/getSignedSteps.d.ts +143 -0
  50. package/pipeline/getSignedSteps.js +95 -0
  51. package/pipeline/getSignedSteps.js.map +1 -0
  52. package/pipeline/getTemplate.d.ts +120 -0
  53. package/pipeline/getTemplate.js +83 -0
  54. package/pipeline/getTemplate.js.map +1 -0
  55. package/pipeline/index.d.ts +9 -0
  56. package/pipeline/index.js +12 -1
  57. package/pipeline/index.js.map +1 -1
  58. package/pipeline/pipeline.d.ts +116 -101
  59. package/pipeline/pipeline.js +18 -16
  60. package/pipeline/pipeline.js.map +1 -1
  61. package/pipeline/schedule.d.ts +64 -53
  62. package/pipeline/schedule.js +38 -27
  63. package/pipeline/schedule.js.map +1 -1
  64. package/pipeline/team.d.ts +42 -31
  65. package/pipeline/team.js +34 -23
  66. package/pipeline/team.js.map +1 -1
  67. package/pipeline/template.d.ts +157 -0
  68. package/pipeline/template.js +125 -0
  69. package/pipeline/template.js.map +1 -0
  70. package/provider.d.ts +23 -9
  71. package/provider.js +1 -0
  72. package/provider.js.map +1 -1
  73. package/team/getTeam.d.ts +33 -34
  74. package/team/getTeam.js +18 -16
  75. package/team/getTeam.js.map +1 -1
  76. package/team/member.d.ts +44 -44
  77. package/team/member.js +33 -33
  78. package/team/team.d.ts +45 -43
  79. package/team/team.js +26 -24
  80. package/team/team.js.map +1 -1
  81. package/testsuite/team.d.ts +48 -52
  82. package/testsuite/team.js +43 -47
  83. package/testsuite/team.js.map +1 -1
  84. package/testsuite/testSuite.d.ts +21 -27
  85. package/testsuite/testSuite.js +6 -12
  86. package/testsuite/testSuite.js.map +1 -1
  87. package/types/input.d.ts +37 -21
  88. package/types/output.d.ts +34 -18
  89. package/utilities.d.ts +4 -0
  90. package/utilities.js +33 -1
  91. package/utilities.js.map +1 -1
  92. package/organization/settings.d.ts +0 -80
  93. package/organization/settings.js +0 -81
  94. package/organization/settings.js.map +0 -1
  95. package/scripts/install-pulumi-plugin.js +0 -26
@@ -0,0 +1,132 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * This resource allows you to manage a default queue for a Buildkite Cluster.
4
+ * Find out more information in our [documentation](https://buildkite.com/docs/clusters/overview).
5
+ *
6
+ * ## Example Usage
7
+ *
8
+ * <!--Start PulumiCodeChooser -->
9
+ * ```typescript
10
+ * import * as pulumi from "@pulumi/pulumi";
11
+ * import * as buildkite from "@pulumiverse/buildkite";
12
+ *
13
+ * // create a cluster
14
+ * const primaryCluster = new buildkite.cluster.Cluster("primaryCluster", {
15
+ * description: "Runs the monolith build and deploy",
16
+ * emoji: "🚀",
17
+ * color: "#bada55",
18
+ * });
19
+ * const _default = new buildkite.cluster.ClusterQueue("default", {
20
+ * clusterId: primaryCluster.id,
21
+ * key: "default",
22
+ * });
23
+ * const primaryClusterDefaultQueue = new buildkite.cluster.ClusterDefaultQueue("primaryClusterDefaultQueue", {
24
+ * clusterId: primaryCluster.id,
25
+ * queueId: _default.id,
26
+ * });
27
+ * ```
28
+ * <!--End PulumiCodeChooser -->
29
+ *
30
+ * ## Import
31
+ *
32
+ * import a clusters default queue resource using the GraphQL ID of the cluster itself
33
+ *
34
+ * #
35
+ *
36
+ * you can use this query to find the ID:
37
+ *
38
+ * query getClusters {
39
+ *
40
+ * organization(slug: "ORGANIZATION"){
41
+ *
42
+ * clusters(first: 5, order:NAME) {
43
+ *
44
+ * edges{
45
+ *
46
+ * node {
47
+ *
48
+ * id
49
+ *
50
+ * name
51
+ *
52
+ * }
53
+ *
54
+ * }
55
+ *
56
+ * }
57
+ *
58
+ * }
59
+ *
60
+ * }
61
+ *
62
+ * ```sh
63
+ * $ pulumi import buildkite:Cluster/clusterDefaultQueue:ClusterDefaultQueue primary Q2x1c3Rlci0tLTI3ZmFmZjA4LTA3OWEtNDk5ZC1hMmIwLTIzNmY3NWFkMWZjYg==
64
+ * ```
65
+ */
66
+ export declare class ClusterDefaultQueue extends pulumi.CustomResource {
67
+ /**
68
+ * Get an existing ClusterDefaultQueue resource's state with the given name, ID, and optional extra
69
+ * properties used to qualify the lookup.
70
+ *
71
+ * @param name The _unique_ name of the resulting resource.
72
+ * @param id The _unique_ provider ID of the resource to lookup.
73
+ * @param state Any extra arguments used during the lookup.
74
+ * @param opts Optional settings to control the behavior of the CustomResource.
75
+ */
76
+ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ClusterDefaultQueueState, opts?: pulumi.CustomResourceOptions): ClusterDefaultQueue;
77
+ /**
78
+ * Returns true if the given object is an instance of ClusterDefaultQueue. This is designed to work even
79
+ * when multiple copies of the Pulumi SDK have been loaded into the same process.
80
+ */
81
+ static isInstance(obj: any): obj is ClusterDefaultQueue;
82
+ /**
83
+ * The GraphQL ID of the cluster to which to add a default queue.
84
+ */
85
+ readonly clusterId: pulumi.Output<string>;
86
+ /**
87
+ * The GraphQL ID of the cluster queue to set as default on the cluster.
88
+ */
89
+ readonly queueId: pulumi.Output<string>;
90
+ /**
91
+ * The UUID of the cluster.
92
+ */
93
+ readonly uuid: pulumi.Output<string>;
94
+ /**
95
+ * Create a ClusterDefaultQueue resource with the given unique name, arguments, and options.
96
+ *
97
+ * @param name The _unique_ name of the resource.
98
+ * @param args The arguments to use to populate this resource's properties.
99
+ * @param opts A bag of options that control this resource's behavior.
100
+ */
101
+ constructor(name: string, args: ClusterDefaultQueueArgs, opts?: pulumi.CustomResourceOptions);
102
+ }
103
+ /**
104
+ * Input properties used for looking up and filtering ClusterDefaultQueue resources.
105
+ */
106
+ export interface ClusterDefaultQueueState {
107
+ /**
108
+ * The GraphQL ID of the cluster to which to add a default queue.
109
+ */
110
+ clusterId?: pulumi.Input<string>;
111
+ /**
112
+ * The GraphQL ID of the cluster queue to set as default on the cluster.
113
+ */
114
+ queueId?: pulumi.Input<string>;
115
+ /**
116
+ * The UUID of the cluster.
117
+ */
118
+ uuid?: pulumi.Input<string>;
119
+ }
120
+ /**
121
+ * The set of arguments for constructing a ClusterDefaultQueue resource.
122
+ */
123
+ export interface ClusterDefaultQueueArgs {
124
+ /**
125
+ * The GraphQL ID of the cluster to which to add a default queue.
126
+ */
127
+ clusterId: pulumi.Input<string>;
128
+ /**
129
+ * The GraphQL ID of the cluster queue to set as default on the cluster.
130
+ */
131
+ queueId: pulumi.Input<string>;
132
+ }
@@ -0,0 +1,123 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.ClusterDefaultQueue = void 0;
6
+ const pulumi = require("@pulumi/pulumi");
7
+ const utilities = require("../utilities");
8
+ /**
9
+ * This resource allows you to manage a default queue for a Buildkite Cluster.
10
+ * Find out more information in our [documentation](https://buildkite.com/docs/clusters/overview).
11
+ *
12
+ * ## Example Usage
13
+ *
14
+ * <!--Start PulumiCodeChooser -->
15
+ * ```typescript
16
+ * import * as pulumi from "@pulumi/pulumi";
17
+ * import * as buildkite from "@pulumiverse/buildkite";
18
+ *
19
+ * // create a cluster
20
+ * const primaryCluster = new buildkite.cluster.Cluster("primaryCluster", {
21
+ * description: "Runs the monolith build and deploy",
22
+ * emoji: "🚀",
23
+ * color: "#bada55",
24
+ * });
25
+ * const _default = new buildkite.cluster.ClusterQueue("default", {
26
+ * clusterId: primaryCluster.id,
27
+ * key: "default",
28
+ * });
29
+ * const primaryClusterDefaultQueue = new buildkite.cluster.ClusterDefaultQueue("primaryClusterDefaultQueue", {
30
+ * clusterId: primaryCluster.id,
31
+ * queueId: _default.id,
32
+ * });
33
+ * ```
34
+ * <!--End PulumiCodeChooser -->
35
+ *
36
+ * ## Import
37
+ *
38
+ * import a clusters default queue resource using the GraphQL ID of the cluster itself
39
+ *
40
+ * #
41
+ *
42
+ * you can use this query to find the ID:
43
+ *
44
+ * query getClusters {
45
+ *
46
+ * organization(slug: "ORGANIZATION"){
47
+ *
48
+ * clusters(first: 5, order:NAME) {
49
+ *
50
+ * edges{
51
+ *
52
+ * node {
53
+ *
54
+ * id
55
+ *
56
+ * name
57
+ *
58
+ * }
59
+ *
60
+ * }
61
+ *
62
+ * }
63
+ *
64
+ * }
65
+ *
66
+ * }
67
+ *
68
+ * ```sh
69
+ * $ pulumi import buildkite:Cluster/clusterDefaultQueue:ClusterDefaultQueue primary Q2x1c3Rlci0tLTI3ZmFmZjA4LTA3OWEtNDk5ZC1hMmIwLTIzNmY3NWFkMWZjYg==
70
+ * ```
71
+ */
72
+ class ClusterDefaultQueue extends pulumi.CustomResource {
73
+ /**
74
+ * Get an existing ClusterDefaultQueue resource's state with the given name, ID, and optional extra
75
+ * properties used to qualify the lookup.
76
+ *
77
+ * @param name The _unique_ name of the resulting resource.
78
+ * @param id The _unique_ provider ID of the resource to lookup.
79
+ * @param state Any extra arguments used during the lookup.
80
+ * @param opts Optional settings to control the behavior of the CustomResource.
81
+ */
82
+ static get(name, id, state, opts) {
83
+ return new ClusterDefaultQueue(name, state, Object.assign(Object.assign({}, opts), { id: id }));
84
+ }
85
+ /**
86
+ * Returns true if the given object is an instance of ClusterDefaultQueue. This is designed to work even
87
+ * when multiple copies of the Pulumi SDK have been loaded into the same process.
88
+ */
89
+ static isInstance(obj) {
90
+ if (obj === undefined || obj === null) {
91
+ return false;
92
+ }
93
+ return obj['__pulumiType'] === ClusterDefaultQueue.__pulumiType;
94
+ }
95
+ constructor(name, argsOrState, opts) {
96
+ let resourceInputs = {};
97
+ opts = opts || {};
98
+ if (opts.id) {
99
+ const state = argsOrState;
100
+ resourceInputs["clusterId"] = state ? state.clusterId : undefined;
101
+ resourceInputs["queueId"] = state ? state.queueId : undefined;
102
+ resourceInputs["uuid"] = state ? state.uuid : undefined;
103
+ }
104
+ else {
105
+ const args = argsOrState;
106
+ if ((!args || args.clusterId === undefined) && !opts.urn) {
107
+ throw new Error("Missing required property 'clusterId'");
108
+ }
109
+ if ((!args || args.queueId === undefined) && !opts.urn) {
110
+ throw new Error("Missing required property 'queueId'");
111
+ }
112
+ resourceInputs["clusterId"] = args ? args.clusterId : undefined;
113
+ resourceInputs["queueId"] = args ? args.queueId : undefined;
114
+ resourceInputs["uuid"] = undefined /*out*/;
115
+ }
116
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
117
+ super(ClusterDefaultQueue.__pulumiType, name, resourceInputs, opts);
118
+ }
119
+ }
120
+ exports.ClusterDefaultQueue = ClusterDefaultQueue;
121
+ /** @internal */
122
+ ClusterDefaultQueue.__pulumiType = 'buildkite:Cluster/clusterDefaultQueue:ClusterDefaultQueue';
123
+ //# sourceMappingURL=clusterDefaultQueue.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"clusterDefaultQueue.js","sourceRoot":"","sources":["../../cluster/clusterDefaultQueue.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAE1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+DG;AACH,MAAa,mBAAoB,SAAQ,MAAM,CAAC,cAAc;IAC1D;;;;;;;;OAQG;IACI,MAAM,CAAC,GAAG,CAAC,IAAY,EAAE,EAA2B,EAAE,KAAgC,EAAE,IAAmC;QAC9H,OAAO,IAAI,mBAAmB,CAAC,IAAI,EAAO,KAAK,kCAAO,IAAI,KAAE,EAAE,EAAE,EAAE,IAAG,CAAC;IAC1E,CAAC;IAKD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,EAAE;YACnC,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,GAAG,CAAC,cAAc,CAAC,KAAK,mBAAmB,CAAC,YAAY,CAAC;IACpE,CAAC;IAuBD,YAAY,IAAY,EAAE,WAAgE,EAAE,IAAmC;QAC3H,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nE,KAAK,CAAC,mBAAmB,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IACxE,CAAC;;AAvEL,kDAwEC;AA1DG,gBAAgB;AACO,gCAAY,GAAG,2DAA2D,CAAC"}
@@ -1,77 +1,71 @@
1
1
  import * as pulumi from "@pulumi/pulumi";
2
2
  /**
3
- * ## # Resource: clusterQueue
4
- *
5
- * This resource allows you to create and manage cluster queues.
6
- *
7
- * Buildkite Documentation: https://buildkite.com/docs/clusters/manage-clusters#set-up-clusters-create-a-queue
3
+ * A Cluster Queue is a queue belonging to a specific Cluster for its Agents to target builds on.
8
4
  *
9
5
  * ## Example Usage
10
6
  *
7
+ * <!--Start PulumiCodeChooser -->
11
8
  * ```typescript
12
9
  * import * as pulumi from "@pulumi/pulumi";
13
10
  * import * as buildkite from "@pulumiverse/buildkite";
14
11
  *
15
- * const queue1 = new buildkite.cluster.ClusterQueue("queue1", {
16
- * clusterId: "Q2x1c3Rlci0tLTMzMDc0ZDhiLTM4MjctNDRkNC05YTQ3LTkwN2E2NWZjODViNg==",
17
- * description: "Prod deployment cluster queue",
18
- * key: "prod-deploy",
12
+ * // create a cluster
13
+ * const primary = new buildkite.cluster.Cluster("primary", {
14
+ * description: "Runs the monolith build and deploy",
15
+ * emoji: "🚀",
16
+ * color: "#bada55",
17
+ * });
18
+ * const monolith = new buildkite.pipeline.Pipeline("monolith", {
19
+ * repository: "https://github.com/...",
20
+ * clusterId: primary.id,
21
+ * });
22
+ * // create a queue to put pipeline builds in
23
+ * const _default = new buildkite.cluster.ClusterQueue("default", {
24
+ * clusterId: primary.id,
25
+ * key: "default",
19
26
  * });
20
27
  * ```
28
+ * <!--End PulumiCodeChooser -->
21
29
  *
22
30
  * ## Import
23
31
  *
24
- * Cluster queues can be imported using its `GraphQL ID`, along with its respective cluster `UUID`, separated by a comma. e.g.
25
- *
26
- * ```sh
27
- * $ pulumi import buildkite:Cluster/clusterQueue:ClusterQueue test Q2x1c3RlclF1ZXVlLS0tYjJiOGRhNTEtOWY5My00Y2MyLTkyMjktMGRiNzg3ZDQzOTAz,35498aaf-ad05-4fa5-9a07-91bf6cacd2bd
28
- * ```
29
- *
30
- * To find the cluster's `UUID` to utilize, you can use the below GraphQL query below. Alternatively, you can use this [pre-saved query](https://buildkite.com/user/graphql/console/3adf0389-02bd-45ef-adcd-4e8e5ae57f25), where you will need fo fill in the organization slug (ORGANIZATION_SLUG) for obtaining the relevant cluster name/`UUID` that the cluster queue is in. graphql query getClusters {
32
+ * import a cluster queue resource using the GraphQL ID along with its respective cluster UUID
31
33
  *
32
- * organization(slug"ORGANIZATION_SLUG") {
34
+ * #
33
35
  *
34
- * clusters(first50) {
36
+ * you can use this query to find the ID:
35
37
  *
36
- * edges{
38
+ * query getClusterQueues {
37
39
  *
38
- * node{
40
+ * organization(slug: "ORGANIZATION_SLUG") {
39
41
  *
40
- * name
42
+ * cluster(id: "CLUSTER_UUID") {
41
43
  *
42
- * uuid
44
+ * queues(first: 50) {
43
45
  *
44
- * }
46
+ * edges {
45
47
  *
46
- * }
48
+ * node {
47
49
  *
48
- * }
50
+ * id
49
51
  *
50
- * } } After the cluster `UUID` has been found, you can use the below GraphQL query to find the cluster queue's `GraphQL ID`. Alternatively, this [pre-saved query](https://buildkite.com/user/graphql/console/1d913905-900e-40e7-8f46-651543487b5a) can be used, specifying the organization slug (ORGANIZATION_SLUG) and the cluster `UUID` from above (CLUSTER_UUID). graphql query getClusterQueues {
52
+ * key
51
53
  *
52
- * organization(slug"ORGANIZATION_SLUG") {
54
+ * }
53
55
  *
54
- * cluster(id"CLUSTER_UUID") {
56
+ * }
55
57
  *
56
- * queues(first50) {
58
+ * }
57
59
  *
58
- * edges {
60
+ * }
59
61
  *
60
- * node {
62
+ * }
61
63
  *
62
- * id
64
+ * }
63
65
  *
64
- * key
65
- *
66
- * }
67
- *
68
- * }
69
- *
70
- * }
71
- *
72
- * }
73
- *
74
- * } }
66
+ * ```sh
67
+ * $ pulumi import buildkite:Cluster/clusterQueue:ClusterQueue test Q2x1c3RlclF1ZXVlLS0tYjJiOGRhNTEtOWY5My00Y2MyLTkyMjktMGRiNzg3ZDQzOTAz,35498aaf-ad05-4fa5-9a07-91bf6cacd2bd
68
+ * ```
75
69
  */
76
70
  export declare class ClusterQueue extends pulumi.CustomResource {
77
71
  /**
@@ -94,11 +88,11 @@ export declare class ClusterQueue extends pulumi.CustomResource {
94
88
  */
95
89
  readonly clusterId: pulumi.Output<string>;
96
90
  /**
97
- * The UUID of the cluster that this cluster queue belongs to.
91
+ * The UUID of the cluster this queue belongs to.
98
92
  */
99
93
  readonly clusterUuid: pulumi.Output<string>;
100
94
  /**
101
- * The description of the cluster queue.
95
+ * A description for the cluster queue.
102
96
  */
103
97
  readonly description: pulumi.Output<string | undefined>;
104
98
  /**
@@ -106,7 +100,7 @@ export declare class ClusterQueue extends pulumi.CustomResource {
106
100
  */
107
101
  readonly key: pulumi.Output<string>;
108
102
  /**
109
- * The UUID of the created cluster queue.
103
+ * The UUID of the cluster queue.
110
104
  */
111
105
  readonly uuid: pulumi.Output<string>;
112
106
  /**
@@ -127,11 +121,11 @@ export interface ClusterQueueState {
127
121
  */
128
122
  clusterId?: pulumi.Input<string>;
129
123
  /**
130
- * The UUID of the cluster that this cluster queue belongs to.
124
+ * The UUID of the cluster this queue belongs to.
131
125
  */
132
126
  clusterUuid?: pulumi.Input<string>;
133
127
  /**
134
- * The description of the cluster queue.
128
+ * A description for the cluster queue.
135
129
  */
136
130
  description?: pulumi.Input<string>;
137
131
  /**
@@ -139,7 +133,7 @@ export interface ClusterQueueState {
139
133
  */
140
134
  key?: pulumi.Input<string>;
141
135
  /**
142
- * The UUID of the created cluster queue.
136
+ * The UUID of the cluster queue.
143
137
  */
144
138
  uuid?: pulumi.Input<string>;
145
139
  }
@@ -152,7 +146,7 @@ export interface ClusterQueueArgs {
152
146
  */
153
147
  clusterId: pulumi.Input<string>;
154
148
  /**
155
- * The description of the cluster queue.
149
+ * A description for the cluster queue.
156
150
  */
157
151
  description?: pulumi.Input<string>;
158
152
  /**
@@ -6,78 +6,72 @@ exports.ClusterQueue = void 0;
6
6
  const pulumi = require("@pulumi/pulumi");
7
7
  const utilities = require("../utilities");
8
8
  /**
9
- * ## # Resource: clusterQueue
10
- *
11
- * This resource allows you to create and manage cluster queues.
12
- *
13
- * Buildkite Documentation: https://buildkite.com/docs/clusters/manage-clusters#set-up-clusters-create-a-queue
9
+ * A Cluster Queue is a queue belonging to a specific Cluster for its Agents to target builds on.
14
10
  *
15
11
  * ## Example Usage
16
12
  *
13
+ * <!--Start PulumiCodeChooser -->
17
14
  * ```typescript
18
15
  * import * as pulumi from "@pulumi/pulumi";
19
16
  * import * as buildkite from "@pulumiverse/buildkite";
20
17
  *
21
- * const queue1 = new buildkite.cluster.ClusterQueue("queue1", {
22
- * clusterId: "Q2x1c3Rlci0tLTMzMDc0ZDhiLTM4MjctNDRkNC05YTQ3LTkwN2E2NWZjODViNg==",
23
- * description: "Prod deployment cluster queue",
24
- * key: "prod-deploy",
18
+ * // create a cluster
19
+ * const primary = new buildkite.cluster.Cluster("primary", {
20
+ * description: "Runs the monolith build and deploy",
21
+ * emoji: "🚀",
22
+ * color: "#bada55",
23
+ * });
24
+ * const monolith = new buildkite.pipeline.Pipeline("monolith", {
25
+ * repository: "https://github.com/...",
26
+ * clusterId: primary.id,
27
+ * });
28
+ * // create a queue to put pipeline builds in
29
+ * const _default = new buildkite.cluster.ClusterQueue("default", {
30
+ * clusterId: primary.id,
31
+ * key: "default",
25
32
  * });
26
33
  * ```
34
+ * <!--End PulumiCodeChooser -->
27
35
  *
28
36
  * ## Import
29
37
  *
30
- * Cluster queues can be imported using its `GraphQL ID`, along with its respective cluster `UUID`, separated by a comma. e.g.
31
- *
32
- * ```sh
33
- * $ pulumi import buildkite:Cluster/clusterQueue:ClusterQueue test Q2x1c3RlclF1ZXVlLS0tYjJiOGRhNTEtOWY5My00Y2MyLTkyMjktMGRiNzg3ZDQzOTAz,35498aaf-ad05-4fa5-9a07-91bf6cacd2bd
34
- * ```
35
- *
36
- * To find the cluster's `UUID` to utilize, you can use the below GraphQL query below. Alternatively, you can use this [pre-saved query](https://buildkite.com/user/graphql/console/3adf0389-02bd-45ef-adcd-4e8e5ae57f25), where you will need fo fill in the organization slug (ORGANIZATION_SLUG) for obtaining the relevant cluster name/`UUID` that the cluster queue is in. graphql query getClusters {
38
+ * import a cluster queue resource using the GraphQL ID along with its respective cluster UUID
37
39
  *
38
- * organization(slug"ORGANIZATION_SLUG") {
40
+ * #
39
41
  *
40
- * clusters(first50) {
42
+ * you can use this query to find the ID:
41
43
  *
42
- * edges{
44
+ * query getClusterQueues {
43
45
  *
44
- * node{
46
+ * organization(slug: "ORGANIZATION_SLUG") {
45
47
  *
46
- * name
48
+ * cluster(id: "CLUSTER_UUID") {
47
49
  *
48
- * uuid
50
+ * queues(first: 50) {
49
51
  *
50
- * }
52
+ * edges {
51
53
  *
52
- * }
54
+ * node {
53
55
  *
54
- * }
56
+ * id
55
57
  *
56
- * } } After the cluster `UUID` has been found, you can use the below GraphQL query to find the cluster queue's `GraphQL ID`. Alternatively, this [pre-saved query](https://buildkite.com/user/graphql/console/1d913905-900e-40e7-8f46-651543487b5a) can be used, specifying the organization slug (ORGANIZATION_SLUG) and the cluster `UUID` from above (CLUSTER_UUID). graphql query getClusterQueues {
58
+ * key
57
59
  *
58
- * organization(slug"ORGANIZATION_SLUG") {
60
+ * }
59
61
  *
60
- * cluster(id"CLUSTER_UUID") {
62
+ * }
61
63
  *
62
- * queues(first50) {
64
+ * }
63
65
  *
64
- * edges {
66
+ * }
65
67
  *
66
- * node {
68
+ * }
67
69
  *
68
- * id
70
+ * }
69
71
  *
70
- * key
71
- *
72
- * }
73
- *
74
- * }
75
- *
76
- * }
77
- *
78
- * }
79
- *
80
- * } }
72
+ * ```sh
73
+ * $ pulumi import buildkite:Cluster/clusterQueue:ClusterQueue test Q2x1c3RlclF1ZXVlLS0tYjJiOGRhNTEtOWY5My00Y2MyLTkyMjktMGRiNzg3ZDQzOTAz,35498aaf-ad05-4fa5-9a07-91bf6cacd2bd
74
+ * ```
81
75
  */
82
76
  class ClusterQueue extends pulumi.CustomResource {
83
77
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"clusterQueue.js","sourceRoot":"","sources":["../../cluster/clusterQueue.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAE1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyEG;AACH,MAAa,YAAa,SAAQ,MAAM,CAAC,cAAc;IACnD;;;;;;;;OAQG;IACI,MAAM,CAAC,GAAG,CAAC,IAAY,EAAE,EAA2B,EAAE,KAAyB,EAAE,IAAmC;QACvH,OAAO,IAAI,YAAY,CAAC,IAAI,EAAO,KAAK,kCAAO,IAAI,KAAE,EAAE,EAAE,EAAE,IAAG,CAAC;IACnE,CAAC;IAKD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,EAAE;YACnC,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,GAAG,CAAC,cAAc,CAAC,KAAK,YAAY,CAAC,YAAY,CAAC;IAC7D,CAAC;IA+BD,YAAY,IAAY,EAAE,WAAkD,EAAE,IAAmC;QAC7G,IAAI,cAAc,GAAkB,EAAE,CAAC;QACvC,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAClB,IAAI,IAAI,CAAC,EAAE,EAAE;YACT,MAAM,KAAK,GAAG,WAA4C,CAAC;YAC3D,cAAc,CAAC,WAAW,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC;YAClE,cAAc,CAAC,aAAa,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,W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AAC,OAAO,CAAC;SAC9C;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,YAAY,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IACjE,CAAC;;AAnFL,oCAoFC;AAtEG,gBAAgB;AACO,yBAAY,GAAG,6CAA6C,CAAC"}
@@ -1,11 +1,33 @@
1
1
  import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * Use this data source to retrieve a cluster by name. You can find out more about clusters in the Buildkite [documentation](https://buildkite.com/docs/clusters/overview).
4
+ *
5
+ * ## Example Usage
6
+ *
7
+ * <!--Start PulumiCodeChooser -->
8
+ * ```typescript
9
+ * import * as pulumi from "@pulumi/pulumi";
10
+ * import * as buildkite from "@pulumi/buildkite";
11
+ * import * as buildkite from "@pulumiverse/buildkite";
12
+ *
13
+ * const default = buildkite.Cluster.getCluster({
14
+ * name: "default",
15
+ * });
16
+ * // Assign a pipeline to that cluster
17
+ * const terraform_provider_buildkite = new buildkite.pipeline.Pipeline("terraform-provider-buildkite", {
18
+ * repository: "git@github.com:buildkite/terraform-provider-buildkite.git",
19
+ * clusterId: _default.then(_default => _default.id),
20
+ * });
21
+ * ```
22
+ * <!--End PulumiCodeChooser -->
23
+ */
2
24
  export declare function getCluster(args: GetClusterArgs, opts?: pulumi.InvokeOptions): Promise<GetClusterResult>;
3
25
  /**
4
26
  * A collection of arguments for invoking getCluster.
5
27
  */
6
28
  export interface GetClusterArgs {
7
29
  /**
8
- * The name of the cluster to lookup.
30
+ * The name of the cluster to retrieve.
9
31
  */
10
32
  name: string;
11
33
  }
@@ -14,7 +36,7 @@ export interface GetClusterArgs {
14
36
  */
15
37
  export interface GetClusterResult {
16
38
  /**
17
- * The color given the cluster.
39
+ * The color of the cluster.
18
40
  */
19
41
  readonly color: string;
20
42
  /**
@@ -22,26 +44,51 @@ export interface GetClusterResult {
22
44
  */
23
45
  readonly description: string;
24
46
  /**
25
- * The emoji given the cluster.
47
+ * The emoji of the cluster.
26
48
  */
27
49
  readonly emoji: string;
28
50
  /**
29
51
  * The GraphQL ID of the cluster.
30
52
  */
31
53
  readonly id: string;
54
+ /**
55
+ * The name of the cluster to retrieve.
56
+ */
32
57
  readonly name: string;
33
58
  /**
34
- * The UUID of the cluster.
59
+ * The UUID of the cluster
35
60
  */
36
61
  readonly uuid: string;
37
62
  }
63
+ /**
64
+ * Use this data source to retrieve a cluster by name. You can find out more about clusters in the Buildkite [documentation](https://buildkite.com/docs/clusters/overview).
65
+ *
66
+ * ## Example Usage
67
+ *
68
+ * <!--Start PulumiCodeChooser -->
69
+ * ```typescript
70
+ * import * as pulumi from "@pulumi/pulumi";
71
+ * import * as buildkite from "@pulumi/buildkite";
72
+ * import * as buildkite from "@pulumiverse/buildkite";
73
+ *
74
+ * const default = buildkite.Cluster.getCluster({
75
+ * name: "default",
76
+ * });
77
+ * // Assign a pipeline to that cluster
78
+ * const terraform_provider_buildkite = new buildkite.pipeline.Pipeline("terraform-provider-buildkite", {
79
+ * repository: "git@github.com:buildkite/terraform-provider-buildkite.git",
80
+ * clusterId: _default.then(_default => _default.id),
81
+ * });
82
+ * ```
83
+ * <!--End PulumiCodeChooser -->
84
+ */
38
85
  export declare function getClusterOutput(args: GetClusterOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GetClusterResult>;
39
86
  /**
40
87
  * A collection of arguments for invoking getCluster.
41
88
  */
42
89
  export interface GetClusterOutputArgs {
43
90
  /**
44
- * The name of the cluster to lookup.
91
+ * The name of the cluster to retrieve.
45
92
  */
46
93
  name: pulumi.Input<string>;
47
94
  }