@pulumiverse/buildkite 3.1.6 → 3.2.0
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.
- package/agent/agentToken.d.ts +0 -2
- package/agent/agentToken.js +6 -8
- package/agent/agentToken.js.map +1 -1
- package/agent/index.js +1 -1
- package/agent/index.js.map +1 -1
- package/cluster/cluster.d.ts +4 -4
- package/cluster/cluster.js +15 -15
- package/cluster/cluster.js.map +1 -1
- package/cluster/clusterAgentToken.d.ts +5 -5
- package/cluster/clusterAgentToken.js +18 -18
- package/cluster/clusterAgentToken.js.map +1 -1
- package/cluster/clusterDefaultQueue.d.ts +15 -8
- package/cluster/clusterDefaultQueue.js +18 -17
- package/cluster/clusterDefaultQueue.js.map +1 -1
- package/cluster/clusterMaintainer.d.ts +159 -0
- package/cluster/clusterMaintainer.js +107 -0
- package/cluster/clusterMaintainer.js.map +1 -0
- package/cluster/clusterQueue.d.ts +64 -4
- package/cluster/clusterQueue.js +44 -16
- package/cluster/clusterQueue.js.map +1 -1
- package/cluster/clusterSecret.d.ts +148 -0
- package/cluster/clusterSecret.js +108 -0
- package/cluster/clusterSecret.js.map +1 -0
- package/cluster/getCluster.d.ts +12 -9
- package/cluster/getCluster.js +11 -10
- package/cluster/getCluster.js.map +1 -1
- package/cluster/getClusters.d.ts +22 -0
- package/cluster/getClusters.js +26 -0
- package/cluster/getClusters.js.map +1 -0
- package/cluster/index.d.ts +9 -0
- package/cluster/index.js +15 -2
- package/cluster/index.js.map +1 -1
- package/config/index.js +1 -1
- package/config/index.js.map +1 -1
- package/config/vars.d.ts +7 -6
- package/config/vars.js +7 -1
- package/config/vars.js.map +1 -1
- package/getMeta.d.ts +21 -19
- package/getMeta.js +23 -20
- package/getMeta.js.map +1 -1
- package/index.d.ts +1 -3
- package/index.js +19 -5
- package/index.js.map +1 -1
- package/organization/banner.d.ts +2 -4
- package/organization/banner.js +8 -10
- package/organization/banner.js.map +1 -1
- package/organization/getMember.d.ts +94 -0
- package/organization/getMember.js +74 -0
- package/organization/getMember.js.map +1 -0
- package/organization/getMembers.d.ts +40 -0
- package/organization/getMembers.js +44 -0
- package/organization/getMembers.js.map +1 -0
- package/organization/getOrganization.d.ts +1 -1
- package/organization/getOrganization.js +3 -2
- package/organization/getOrganization.js.map +1 -1
- package/organization/getPortal.d.ts +95 -0
- package/organization/getPortal.js +50 -0
- package/organization/getPortal.js.map +1 -0
- package/organization/getPortals.d.ts +40 -0
- package/organization/getPortals.js +44 -0
- package/organization/getPortals.js.map +1 -0
- package/organization/getRegistry.d.ts +78 -0
- package/organization/getRegistry.js +34 -0
- package/organization/getRegistry.js.map +1 -0
- package/organization/getRule.d.ts +124 -0
- package/organization/getRule.js +72 -0
- package/organization/getRule.js.map +1 -0
- package/organization/index.d.ts +27 -0
- package/organization/index.js +35 -2
- package/organization/index.js.map +1 -1
- package/organization/organization.d.ts +3 -3
- package/organization/organization.js +10 -10
- package/organization/organization.js.map +1 -1
- package/organization/portal.d.ts +217 -0
- package/organization/portal.js +150 -0
- package/organization/portal.js.map +1 -0
- package/organization/registry.d.ts +161 -0
- package/organization/registry.js +87 -0
- package/organization/registry.js.map +1 -0
- package/organization/rule.d.ts +267 -0
- package/organization/rule.js +212 -0
- package/organization/rule.js.map +1 -0
- package/package.json +2 -1
- package/pipeline/getPipeline.d.ts +11 -7
- package/pipeline/getPipeline.js +7 -8
- package/pipeline/getPipeline.js.map +1 -1
- package/pipeline/getSignedSteps.d.ts +8 -49
- package/pipeline/getSignedSteps.js +13 -50
- package/pipeline/getSignedSteps.js.map +1 -1
- package/pipeline/getTemplate.d.ts +9 -11
- package/pipeline/getTemplate.js +15 -12
- package/pipeline/getTemplate.js.map +1 -1
- package/pipeline/index.d.ts +3 -0
- package/pipeline/index.js +7 -2
- package/pipeline/index.js.map +1 -1
- package/pipeline/pipeline.d.ts +30 -14
- package/pipeline/pipeline.js +54 -48
- package/pipeline/pipeline.js.map +1 -1
- package/pipeline/schedule.d.ts +8 -7
- package/pipeline/schedule.js +31 -30
- package/pipeline/schedule.js.map +1 -1
- package/pipeline/team.d.ts +8 -6
- package/pipeline/team.js +20 -18
- package/pipeline/team.js.map +1 -1
- package/pipeline/template.d.ts +11 -11
- package/pipeline/template.js +23 -23
- package/pipeline/template.js.map +1 -1
- package/pipeline/webhook.d.ts +120 -0
- package/pipeline/webhook.js +111 -0
- package/pipeline/webhook.js.map +1 -0
- package/provider.d.ts +24 -24
- package/provider.js +16 -7
- package/provider.js.map +1 -1
- package/team/getTeam.d.ts +21 -9
- package/team/getTeam.js +11 -10
- package/team/getTeam.js.map +1 -1
- package/team/getTeams.d.ts +22 -0
- package/team/getTeams.js +26 -0
- package/team/getTeams.js.map +1 -0
- package/team/index.d.ts +3 -0
- package/team/index.js +5 -2
- package/team/index.js.map +1 -1
- package/team/member.d.ts +4 -5
- package/team/member.js +16 -17
- package/team/member.js.map +1 -1
- package/team/team.d.ts +54 -7
- package/team/team.js +32 -25
- package/team/team.js.map +1 -1
- package/testsuite/getTestSuite.d.ts +90 -0
- package/testsuite/getTestSuite.js +66 -0
- package/testsuite/getTestSuite.js.map +1 -0
- package/testsuite/index.d.ts +3 -0
- package/testsuite/index.js +5 -2
- package/testsuite/index.js.map +1 -1
- package/testsuite/team.d.ts +4 -5
- package/testsuite/team.js +16 -17
- package/testsuite/team.js.map +1 -1
- package/testsuite/testSuite.d.ts +50 -2
- package/testsuite/testSuite.js +53 -15
- package/testsuite/testSuite.js.map +1 -1
- package/types/index.js +1 -1
- package/types/index.js.map +1 -1
- package/types/input.d.ts +81 -5
- package/types/input.js +1 -1
- package/types/input.js.map +1 -1
- package/types/output.d.ts +323 -5
- package/types/output.js +1 -1
- package/types/output.js.map +1 -1
- package/utilities.d.ts +0 -4
- package/utilities.js +20 -30
- package/utilities.js.map +1 -1
- package/package.json.bak +0 -28
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
/**
|
|
3
|
+
* This resource allows you to manage cluster maintainers in Buildkite. Maintainers can be either users or teams
|
|
4
|
+
* that have permission to manage a specific cluster. Find out more information in our
|
|
5
|
+
* [documentation](https://buildkite.com/docs/clusters/manage-clusters).
|
|
6
|
+
*
|
|
7
|
+
* ## Example Usage
|
|
8
|
+
*
|
|
9
|
+
* ```typescript
|
|
10
|
+
* import * as pulumi from "@pulumi/pulumi";
|
|
11
|
+
* import * as buildkite from "@pulumiverse/buildkite";
|
|
12
|
+
*
|
|
13
|
+
* // Add a user as a cluster maintainer
|
|
14
|
+
* const userMaintainer = new buildkite.cluster.ClusterMaintainer("user_maintainer", {
|
|
15
|
+
* clusterUuid: primary.uuid,
|
|
16
|
+
* userUuid: "01234567-89ab-cdef-0123-456789abcdef",
|
|
17
|
+
* });
|
|
18
|
+
* // Add a team as a cluster maintainer
|
|
19
|
+
* const teamMaintainer = new buildkite.cluster.ClusterMaintainer("team_maintainer", {
|
|
20
|
+
* clusterUuid: primary.uuid,
|
|
21
|
+
* teamUuid: "01234567-89ab-cdef-0123-456789abcdef",
|
|
22
|
+
* });
|
|
23
|
+
* ```
|
|
24
|
+
*
|
|
25
|
+
* ## Import
|
|
26
|
+
*
|
|
27
|
+
* Using `pulumi import`, import resources using the `id`. For example:
|
|
28
|
+
*
|
|
29
|
+
* Import a cluster maintainer using {cluster_uuid}/{permission_uuid}
|
|
30
|
+
*
|
|
31
|
+
* You can find the cluster_uuid and the permission_uuid
|
|
32
|
+
*
|
|
33
|
+
* from the maintainers list using the cluster data source or REST
|
|
34
|
+
*
|
|
35
|
+
* API response from:
|
|
36
|
+
*
|
|
37
|
+
* GET /v2/organizations/{org_slug}/clusters/{cluster_uuid}/maintainers
|
|
38
|
+
*
|
|
39
|
+
* ```sh
|
|
40
|
+
* $ pulumi import buildkite:Cluster/clusterMaintainer:ClusterMaintainer user_maintainer 01234567-89ab-cdef-0123-456789abcdef/977b68d3-f8fe-4784-8d43-5bc857e10541
|
|
41
|
+
* ```
|
|
42
|
+
*/
|
|
43
|
+
export declare class ClusterMaintainer extends pulumi.CustomResource {
|
|
44
|
+
/**
|
|
45
|
+
* Get an existing ClusterMaintainer resource's state with the given name, ID, and optional extra
|
|
46
|
+
* properties used to qualify the lookup.
|
|
47
|
+
*
|
|
48
|
+
* @param name The _unique_ name of the resulting resource.
|
|
49
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
50
|
+
* @param state Any extra arguments used during the lookup.
|
|
51
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
52
|
+
*/
|
|
53
|
+
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ClusterMaintainerState, opts?: pulumi.CustomResourceOptions): ClusterMaintainer;
|
|
54
|
+
/**
|
|
55
|
+
* Returns true if the given object is an instance of ClusterMaintainer. This is designed to work even
|
|
56
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
57
|
+
*/
|
|
58
|
+
static isInstance(obj: any): obj is ClusterMaintainer;
|
|
59
|
+
/**
|
|
60
|
+
* The email of the actor (only for users).
|
|
61
|
+
*/
|
|
62
|
+
readonly actorEmail: pulumi.Output<string>;
|
|
63
|
+
/**
|
|
64
|
+
* The name of the actor.
|
|
65
|
+
*/
|
|
66
|
+
readonly actorName: pulumi.Output<string>;
|
|
67
|
+
/**
|
|
68
|
+
* The slug of the actor (only for teams).
|
|
69
|
+
*/
|
|
70
|
+
readonly actorSlug: pulumi.Output<string>;
|
|
71
|
+
/**
|
|
72
|
+
* The type of the actor (user or team).
|
|
73
|
+
*/
|
|
74
|
+
readonly actorType: pulumi.Output<string>;
|
|
75
|
+
/**
|
|
76
|
+
* The UUID of the actor (user or team) that is the maintainer.
|
|
77
|
+
*/
|
|
78
|
+
readonly actorUuid: pulumi.Output<string>;
|
|
79
|
+
/**
|
|
80
|
+
* The UUID of the cluster.
|
|
81
|
+
*/
|
|
82
|
+
readonly clusterUuid: pulumi.Output<string>;
|
|
83
|
+
/**
|
|
84
|
+
* The UUID of the team to add as a maintainer. This is mutually exclusive with user*uuid.
|
|
85
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
86
|
+
*/
|
|
87
|
+
readonly teamUuid: pulumi.Output<string | undefined>;
|
|
88
|
+
/**
|
|
89
|
+
* The UUID of the user to add as a maintainer. This is mutually exclusive with team*uuid.
|
|
90
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
91
|
+
*/
|
|
92
|
+
readonly userUuid: pulumi.Output<string | undefined>;
|
|
93
|
+
/**
|
|
94
|
+
* Create a ClusterMaintainer resource with the given unique name, arguments, and options.
|
|
95
|
+
*
|
|
96
|
+
* @param name The _unique_ name of the resource.
|
|
97
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
98
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
99
|
+
*/
|
|
100
|
+
constructor(name: string, args: ClusterMaintainerArgs, opts?: pulumi.CustomResourceOptions);
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Input properties used for looking up and filtering ClusterMaintainer resources.
|
|
104
|
+
*/
|
|
105
|
+
export interface ClusterMaintainerState {
|
|
106
|
+
/**
|
|
107
|
+
* The email of the actor (only for users).
|
|
108
|
+
*/
|
|
109
|
+
actorEmail?: pulumi.Input<string>;
|
|
110
|
+
/**
|
|
111
|
+
* The name of the actor.
|
|
112
|
+
*/
|
|
113
|
+
actorName?: pulumi.Input<string>;
|
|
114
|
+
/**
|
|
115
|
+
* The slug of the actor (only for teams).
|
|
116
|
+
*/
|
|
117
|
+
actorSlug?: pulumi.Input<string>;
|
|
118
|
+
/**
|
|
119
|
+
* The type of the actor (user or team).
|
|
120
|
+
*/
|
|
121
|
+
actorType?: pulumi.Input<string>;
|
|
122
|
+
/**
|
|
123
|
+
* The UUID of the actor (user or team) that is the maintainer.
|
|
124
|
+
*/
|
|
125
|
+
actorUuid?: pulumi.Input<string>;
|
|
126
|
+
/**
|
|
127
|
+
* The UUID of the cluster.
|
|
128
|
+
*/
|
|
129
|
+
clusterUuid?: pulumi.Input<string>;
|
|
130
|
+
/**
|
|
131
|
+
* The UUID of the team to add as a maintainer. This is mutually exclusive with user*uuid.
|
|
132
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
133
|
+
*/
|
|
134
|
+
teamUuid?: pulumi.Input<string>;
|
|
135
|
+
/**
|
|
136
|
+
* The UUID of the user to add as a maintainer. This is mutually exclusive with team*uuid.
|
|
137
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
138
|
+
*/
|
|
139
|
+
userUuid?: pulumi.Input<string>;
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* The set of arguments for constructing a ClusterMaintainer resource.
|
|
143
|
+
*/
|
|
144
|
+
export interface ClusterMaintainerArgs {
|
|
145
|
+
/**
|
|
146
|
+
* The UUID of the cluster.
|
|
147
|
+
*/
|
|
148
|
+
clusterUuid: pulumi.Input<string>;
|
|
149
|
+
/**
|
|
150
|
+
* The UUID of the team to add as a maintainer. This is mutually exclusive with user*uuid.
|
|
151
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
152
|
+
*/
|
|
153
|
+
teamUuid?: pulumi.Input<string>;
|
|
154
|
+
/**
|
|
155
|
+
* The UUID of the user to add as a maintainer. This is mutually exclusive with team*uuid.
|
|
156
|
+
* Only one of user*uuid or teamUuid can be specified.
|
|
157
|
+
*/
|
|
158
|
+
userUuid?: pulumi.Input<string>;
|
|
159
|
+
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
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.ClusterMaintainer = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("../utilities");
|
|
8
|
+
/**
|
|
9
|
+
* This resource allows you to manage cluster maintainers in Buildkite. Maintainers can be either users or teams
|
|
10
|
+
* that have permission to manage a specific cluster. Find out more information in our
|
|
11
|
+
* [documentation](https://buildkite.com/docs/clusters/manage-clusters).
|
|
12
|
+
*
|
|
13
|
+
* ## Example Usage
|
|
14
|
+
*
|
|
15
|
+
* ```typescript
|
|
16
|
+
* import * as pulumi from "@pulumi/pulumi";
|
|
17
|
+
* import * as buildkite from "@pulumiverse/buildkite";
|
|
18
|
+
*
|
|
19
|
+
* // Add a user as a cluster maintainer
|
|
20
|
+
* const userMaintainer = new buildkite.cluster.ClusterMaintainer("user_maintainer", {
|
|
21
|
+
* clusterUuid: primary.uuid,
|
|
22
|
+
* userUuid: "01234567-89ab-cdef-0123-456789abcdef",
|
|
23
|
+
* });
|
|
24
|
+
* // Add a team as a cluster maintainer
|
|
25
|
+
* const teamMaintainer = new buildkite.cluster.ClusterMaintainer("team_maintainer", {
|
|
26
|
+
* clusterUuid: primary.uuid,
|
|
27
|
+
* teamUuid: "01234567-89ab-cdef-0123-456789abcdef",
|
|
28
|
+
* });
|
|
29
|
+
* ```
|
|
30
|
+
*
|
|
31
|
+
* ## Import
|
|
32
|
+
*
|
|
33
|
+
* Using `pulumi import`, import resources using the `id`. For example:
|
|
34
|
+
*
|
|
35
|
+
* Import a cluster maintainer using {cluster_uuid}/{permission_uuid}
|
|
36
|
+
*
|
|
37
|
+
* You can find the cluster_uuid and the permission_uuid
|
|
38
|
+
*
|
|
39
|
+
* from the maintainers list using the cluster data source or REST
|
|
40
|
+
*
|
|
41
|
+
* API response from:
|
|
42
|
+
*
|
|
43
|
+
* GET /v2/organizations/{org_slug}/clusters/{cluster_uuid}/maintainers
|
|
44
|
+
*
|
|
45
|
+
* ```sh
|
|
46
|
+
* $ pulumi import buildkite:Cluster/clusterMaintainer:ClusterMaintainer user_maintainer 01234567-89ab-cdef-0123-456789abcdef/977b68d3-f8fe-4784-8d43-5bc857e10541
|
|
47
|
+
* ```
|
|
48
|
+
*/
|
|
49
|
+
class ClusterMaintainer extends pulumi.CustomResource {
|
|
50
|
+
/**
|
|
51
|
+
* Get an existing ClusterMaintainer resource's state with the given name, ID, and optional extra
|
|
52
|
+
* properties used to qualify the lookup.
|
|
53
|
+
*
|
|
54
|
+
* @param name The _unique_ name of the resulting resource.
|
|
55
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
56
|
+
* @param state Any extra arguments used during the lookup.
|
|
57
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
58
|
+
*/
|
|
59
|
+
static get(name, id, state, opts) {
|
|
60
|
+
return new ClusterMaintainer(name, state, { ...opts, id: id });
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Returns true if the given object is an instance of ClusterMaintainer. This is designed to work even
|
|
64
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
65
|
+
*/
|
|
66
|
+
static isInstance(obj) {
|
|
67
|
+
if (obj === undefined || obj === null) {
|
|
68
|
+
return false;
|
|
69
|
+
}
|
|
70
|
+
return obj['__pulumiType'] === ClusterMaintainer.__pulumiType;
|
|
71
|
+
}
|
|
72
|
+
constructor(name, argsOrState, opts) {
|
|
73
|
+
let resourceInputs = {};
|
|
74
|
+
opts = opts || {};
|
|
75
|
+
if (opts.id) {
|
|
76
|
+
const state = argsOrState;
|
|
77
|
+
resourceInputs["actorEmail"] = state?.actorEmail;
|
|
78
|
+
resourceInputs["actorName"] = state?.actorName;
|
|
79
|
+
resourceInputs["actorSlug"] = state?.actorSlug;
|
|
80
|
+
resourceInputs["actorType"] = state?.actorType;
|
|
81
|
+
resourceInputs["actorUuid"] = state?.actorUuid;
|
|
82
|
+
resourceInputs["clusterUuid"] = state?.clusterUuid;
|
|
83
|
+
resourceInputs["teamUuid"] = state?.teamUuid;
|
|
84
|
+
resourceInputs["userUuid"] = state?.userUuid;
|
|
85
|
+
}
|
|
86
|
+
else {
|
|
87
|
+
const args = argsOrState;
|
|
88
|
+
if (args?.clusterUuid === undefined && !opts.urn) {
|
|
89
|
+
throw new Error("Missing required property 'clusterUuid'");
|
|
90
|
+
}
|
|
91
|
+
resourceInputs["clusterUuid"] = args?.clusterUuid;
|
|
92
|
+
resourceInputs["teamUuid"] = args?.teamUuid;
|
|
93
|
+
resourceInputs["userUuid"] = args?.userUuid;
|
|
94
|
+
resourceInputs["actorEmail"] = undefined /*out*/;
|
|
95
|
+
resourceInputs["actorName"] = undefined /*out*/;
|
|
96
|
+
resourceInputs["actorSlug"] = undefined /*out*/;
|
|
97
|
+
resourceInputs["actorType"] = undefined /*out*/;
|
|
98
|
+
resourceInputs["actorUuid"] = undefined /*out*/;
|
|
99
|
+
}
|
|
100
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
101
|
+
super(ClusterMaintainer.__pulumiType, name, resourceInputs, opts);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
exports.ClusterMaintainer = ClusterMaintainer;
|
|
105
|
+
/** @internal */
|
|
106
|
+
ClusterMaintainer.__pulumiType = 'buildkite:Cluster/clusterMaintainer:ClusterMaintainer';
|
|
107
|
+
//# sourceMappingURL=clusterMaintainer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"clusterMaintainer.js","sourceRoot":"","sources":["../../cluster/clusterMaintainer.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAE1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,MAAa,iBAAkB,SAAQ,MAAM,CAAC,cAAc;IACxD;;;;;;;;OAQG;IACI,MAAM,CAAC,GAAG,CAAC,IAAY,EAAE,EAA2B,EAAE,KAA8B,EAAE,IAAmC;QAC5H,OAAO,IAAI,iBAAiB,CAAC,IAAI,EAAO,KAAK,EAAE,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACxE,CAAC;IAKD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAA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AAO,CAAC;YACjD,cAAc,CAAC,WAAW,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAChD,cAAc,CAAC,WAAW,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAChD,cAAc,CAAC,WAAW,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAChD,cAAc,CAAC,WAAW,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;SACnD;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,iBAAiB,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IACtE,CAAC;;AApGL,8CAqGC;AAvFG,gBAAgB;AACO,8BAAY,GAAG,uDAAuD,CAAC"}
|
|
@@ -1,21 +1,24 @@
|
|
|
1
1
|
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as inputs from "../types/input";
|
|
3
|
+
import * as outputs from "../types/output";
|
|
2
4
|
/**
|
|
3
5
|
* A Cluster Queue is a queue belonging to a specific Cluster for its Agents to target builds on.
|
|
4
6
|
*
|
|
5
7
|
* ## Example Usage
|
|
6
8
|
*
|
|
7
|
-
* <!--Start PulumiCodeChooser -->
|
|
8
9
|
* ```typescript
|
|
9
10
|
* import * as pulumi from "@pulumi/pulumi";
|
|
10
11
|
* import * as buildkite from "@pulumiverse/buildkite";
|
|
11
12
|
*
|
|
12
13
|
* // create a cluster
|
|
13
14
|
* const primary = new buildkite.cluster.Cluster("primary", {
|
|
15
|
+
* name: "Primary cluster",
|
|
14
16
|
* description: "Runs the monolith build and deploy",
|
|
15
17
|
* emoji: "🚀",
|
|
16
18
|
* color: "#bada55",
|
|
17
19
|
* });
|
|
18
20
|
* const monolith = new buildkite.pipeline.Pipeline("monolith", {
|
|
21
|
+
* name: "Monolith",
|
|
19
22
|
* repository: "https://github.com/...",
|
|
20
23
|
* clusterId: primary.id,
|
|
21
24
|
* });
|
|
@@ -23,15 +26,36 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
23
26
|
* const _default = new buildkite.cluster.ClusterQueue("default", {
|
|
24
27
|
* clusterId: primary.id,
|
|
25
28
|
* key: "default",
|
|
29
|
+
* dispatchPaused: true,
|
|
30
|
+
* });
|
|
31
|
+
* // create a hosted agent queue with macos agents
|
|
32
|
+
* const hostedAgentsMacos = new buildkite.cluster.ClusterQueue("hosted_agents_macos", {
|
|
33
|
+
* clusterId: primary.id,
|
|
34
|
+
* key: "hosted-agents-macos",
|
|
35
|
+
* dispatchPaused: true,
|
|
36
|
+
* hostedAgents: {
|
|
37
|
+
* instanceShape: "MACOS_ARM64_M4_6X28",
|
|
38
|
+
* },
|
|
39
|
+
* });
|
|
40
|
+
* // create a hosted agent queue with linux agents
|
|
41
|
+
* const hostedAgentsLinux = new buildkite.cluster.ClusterQueue("hosted_agents_linux", {
|
|
42
|
+
* clusterId: primary.id,
|
|
43
|
+
* key: "hosted-agents-linux",
|
|
44
|
+
* dispatchPaused: true,
|
|
45
|
+
* hostedAgents: {
|
|
46
|
+
* instanceShape: "LINUX_AMD64_2X4",
|
|
47
|
+
* linux: {
|
|
48
|
+
* agentImageRef: "ubuntu:24.04",
|
|
49
|
+
* },
|
|
50
|
+
* },
|
|
26
51
|
* });
|
|
27
52
|
* ```
|
|
28
|
-
* <!--End PulumiCodeChooser -->
|
|
29
53
|
*
|
|
30
54
|
* ## Import
|
|
31
55
|
*
|
|
32
|
-
*
|
|
56
|
+
* Using `pulumi import`, import resources using the `id`. For example:
|
|
33
57
|
*
|
|
34
|
-
*
|
|
58
|
+
* import a cluster queue resource using the GraphQL ID along with its respective cluster UUID
|
|
35
59
|
*
|
|
36
60
|
* you can use this query to find the ID:
|
|
37
61
|
*
|
|
@@ -95,10 +119,22 @@ export declare class ClusterQueue extends pulumi.CustomResource {
|
|
|
95
119
|
* A description for the cluster queue.
|
|
96
120
|
*/
|
|
97
121
|
readonly description: pulumi.Output<string | undefined>;
|
|
122
|
+
/**
|
|
123
|
+
* The dispatch state of a cluster queue.
|
|
124
|
+
*/
|
|
125
|
+
readonly dispatchPaused: pulumi.Output<boolean>;
|
|
126
|
+
/**
|
|
127
|
+
* Control the settings for the Buildkite hosted agents.
|
|
128
|
+
*/
|
|
129
|
+
readonly hostedAgents: pulumi.Output<outputs.Cluster.ClusterQueueHostedAgents | undefined>;
|
|
98
130
|
/**
|
|
99
131
|
* The key of the cluster queue.
|
|
100
132
|
*/
|
|
101
133
|
readonly key: pulumi.Output<string>;
|
|
134
|
+
/**
|
|
135
|
+
* Specifies which agent should be preferred when a job is retried. Valid values are `prefer-warmest` (prefer agents that have recently finished jobs) and `prefer-different` (prefer a different agent if available). Defaults to `prefer-warmest`.
|
|
136
|
+
*/
|
|
137
|
+
readonly retryAgentAffinity: pulumi.Output<string>;
|
|
102
138
|
/**
|
|
103
139
|
* The UUID of the cluster queue.
|
|
104
140
|
*/
|
|
@@ -128,10 +164,22 @@ export interface ClusterQueueState {
|
|
|
128
164
|
* A description for the cluster queue.
|
|
129
165
|
*/
|
|
130
166
|
description?: pulumi.Input<string>;
|
|
167
|
+
/**
|
|
168
|
+
* The dispatch state of a cluster queue.
|
|
169
|
+
*/
|
|
170
|
+
dispatchPaused?: pulumi.Input<boolean>;
|
|
171
|
+
/**
|
|
172
|
+
* Control the settings for the Buildkite hosted agents.
|
|
173
|
+
*/
|
|
174
|
+
hostedAgents?: pulumi.Input<inputs.Cluster.ClusterQueueHostedAgents>;
|
|
131
175
|
/**
|
|
132
176
|
* The key of the cluster queue.
|
|
133
177
|
*/
|
|
134
178
|
key?: pulumi.Input<string>;
|
|
179
|
+
/**
|
|
180
|
+
* Specifies which agent should be preferred when a job is retried. Valid values are `prefer-warmest` (prefer agents that have recently finished jobs) and `prefer-different` (prefer a different agent if available). Defaults to `prefer-warmest`.
|
|
181
|
+
*/
|
|
182
|
+
retryAgentAffinity?: pulumi.Input<string>;
|
|
135
183
|
/**
|
|
136
184
|
* The UUID of the cluster queue.
|
|
137
185
|
*/
|
|
@@ -149,8 +197,20 @@ export interface ClusterQueueArgs {
|
|
|
149
197
|
* A description for the cluster queue.
|
|
150
198
|
*/
|
|
151
199
|
description?: pulumi.Input<string>;
|
|
200
|
+
/**
|
|
201
|
+
* The dispatch state of a cluster queue.
|
|
202
|
+
*/
|
|
203
|
+
dispatchPaused?: pulumi.Input<boolean>;
|
|
204
|
+
/**
|
|
205
|
+
* Control the settings for the Buildkite hosted agents.
|
|
206
|
+
*/
|
|
207
|
+
hostedAgents?: pulumi.Input<inputs.Cluster.ClusterQueueHostedAgents>;
|
|
152
208
|
/**
|
|
153
209
|
* The key of the cluster queue.
|
|
154
210
|
*/
|
|
155
211
|
key: pulumi.Input<string>;
|
|
212
|
+
/**
|
|
213
|
+
* Specifies which agent should be preferred when a job is retried. Valid values are `prefer-warmest` (prefer agents that have recently finished jobs) and `prefer-different` (prefer a different agent if available). Defaults to `prefer-warmest`.
|
|
214
|
+
*/
|
|
215
|
+
retryAgentAffinity?: pulumi.Input<string>;
|
|
156
216
|
}
|
package/cluster/clusterQueue.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// *** WARNING: this file was generated by
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
3
3
|
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
5
|
exports.ClusterQueue = void 0;
|
|
@@ -10,18 +10,19 @@ const utilities = require("../utilities");
|
|
|
10
10
|
*
|
|
11
11
|
* ## Example Usage
|
|
12
12
|
*
|
|
13
|
-
* <!--Start PulumiCodeChooser -->
|
|
14
13
|
* ```typescript
|
|
15
14
|
* import * as pulumi from "@pulumi/pulumi";
|
|
16
15
|
* import * as buildkite from "@pulumiverse/buildkite";
|
|
17
16
|
*
|
|
18
17
|
* // create a cluster
|
|
19
18
|
* const primary = new buildkite.cluster.Cluster("primary", {
|
|
19
|
+
* name: "Primary cluster",
|
|
20
20
|
* description: "Runs the monolith build and deploy",
|
|
21
21
|
* emoji: "🚀",
|
|
22
22
|
* color: "#bada55",
|
|
23
23
|
* });
|
|
24
24
|
* const monolith = new buildkite.pipeline.Pipeline("monolith", {
|
|
25
|
+
* name: "Monolith",
|
|
25
26
|
* repository: "https://github.com/...",
|
|
26
27
|
* clusterId: primary.id,
|
|
27
28
|
* });
|
|
@@ -29,15 +30,36 @@ const utilities = require("../utilities");
|
|
|
29
30
|
* const _default = new buildkite.cluster.ClusterQueue("default", {
|
|
30
31
|
* clusterId: primary.id,
|
|
31
32
|
* key: "default",
|
|
33
|
+
* dispatchPaused: true,
|
|
34
|
+
* });
|
|
35
|
+
* // create a hosted agent queue with macos agents
|
|
36
|
+
* const hostedAgentsMacos = new buildkite.cluster.ClusterQueue("hosted_agents_macos", {
|
|
37
|
+
* clusterId: primary.id,
|
|
38
|
+
* key: "hosted-agents-macos",
|
|
39
|
+
* dispatchPaused: true,
|
|
40
|
+
* hostedAgents: {
|
|
41
|
+
* instanceShape: "MACOS_ARM64_M4_6X28",
|
|
42
|
+
* },
|
|
43
|
+
* });
|
|
44
|
+
* // create a hosted agent queue with linux agents
|
|
45
|
+
* const hostedAgentsLinux = new buildkite.cluster.ClusterQueue("hosted_agents_linux", {
|
|
46
|
+
* clusterId: primary.id,
|
|
47
|
+
* key: "hosted-agents-linux",
|
|
48
|
+
* dispatchPaused: true,
|
|
49
|
+
* hostedAgents: {
|
|
50
|
+
* instanceShape: "LINUX_AMD64_2X4",
|
|
51
|
+
* linux: {
|
|
52
|
+
* agentImageRef: "ubuntu:24.04",
|
|
53
|
+
* },
|
|
54
|
+
* },
|
|
32
55
|
* });
|
|
33
56
|
* ```
|
|
34
|
-
* <!--End PulumiCodeChooser -->
|
|
35
57
|
*
|
|
36
58
|
* ## Import
|
|
37
59
|
*
|
|
38
|
-
*
|
|
60
|
+
* Using `pulumi import`, import resources using the `id`. For example:
|
|
39
61
|
*
|
|
40
|
-
*
|
|
62
|
+
* import a cluster queue resource using the GraphQL ID along with its respective cluster UUID
|
|
41
63
|
*
|
|
42
64
|
* you can use this query to find the ID:
|
|
43
65
|
*
|
|
@@ -84,7 +106,7 @@ class ClusterQueue extends pulumi.CustomResource {
|
|
|
84
106
|
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
85
107
|
*/
|
|
86
108
|
static get(name, id, state, opts) {
|
|
87
|
-
return new ClusterQueue(name, state,
|
|
109
|
+
return new ClusterQueue(name, state, { ...opts, id: id });
|
|
88
110
|
}
|
|
89
111
|
/**
|
|
90
112
|
* Returns true if the given object is an instance of ClusterQueue. This is designed to work even
|
|
@@ -101,23 +123,29 @@ class ClusterQueue extends pulumi.CustomResource {
|
|
|
101
123
|
opts = opts || {};
|
|
102
124
|
if (opts.id) {
|
|
103
125
|
const state = argsOrState;
|
|
104
|
-
resourceInputs["clusterId"] = state
|
|
105
|
-
resourceInputs["clusterUuid"] = state
|
|
106
|
-
resourceInputs["description"] = state
|
|
107
|
-
resourceInputs["
|
|
108
|
-
resourceInputs["
|
|
126
|
+
resourceInputs["clusterId"] = state?.clusterId;
|
|
127
|
+
resourceInputs["clusterUuid"] = state?.clusterUuid;
|
|
128
|
+
resourceInputs["description"] = state?.description;
|
|
129
|
+
resourceInputs["dispatchPaused"] = state?.dispatchPaused;
|
|
130
|
+
resourceInputs["hostedAgents"] = state?.hostedAgents;
|
|
131
|
+
resourceInputs["key"] = state?.key;
|
|
132
|
+
resourceInputs["retryAgentAffinity"] = state?.retryAgentAffinity;
|
|
133
|
+
resourceInputs["uuid"] = state?.uuid;
|
|
109
134
|
}
|
|
110
135
|
else {
|
|
111
136
|
const args = argsOrState;
|
|
112
|
-
if (
|
|
137
|
+
if (args?.clusterId === undefined && !opts.urn) {
|
|
113
138
|
throw new Error("Missing required property 'clusterId'");
|
|
114
139
|
}
|
|
115
|
-
if (
|
|
140
|
+
if (args?.key === undefined && !opts.urn) {
|
|
116
141
|
throw new Error("Missing required property 'key'");
|
|
117
142
|
}
|
|
118
|
-
resourceInputs["clusterId"] = args
|
|
119
|
-
resourceInputs["description"] = args
|
|
120
|
-
resourceInputs["
|
|
143
|
+
resourceInputs["clusterId"] = args?.clusterId;
|
|
144
|
+
resourceInputs["description"] = args?.description;
|
|
145
|
+
resourceInputs["dispatchPaused"] = args?.dispatchPaused;
|
|
146
|
+
resourceInputs["hostedAgents"] = args?.hostedAgents;
|
|
147
|
+
resourceInputs["key"] = args?.key;
|
|
148
|
+
resourceInputs["retryAgentAffinity"] = args?.retryAgentAffinity;
|
|
121
149
|
resourceInputs["clusterUuid"] = undefined /*out*/;
|
|
122
150
|
resourceInputs["uuid"] = undefined /*out*/;
|
|
123
151
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"clusterQueue.js","sourceRoot":"","sources":["../../cluster/clusterQueue.ts"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"clusterQueue.js","sourceRoot":"","sources":["../../cluster/clusterQueue.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AAGzC,0CAA0C;AAE1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyFG;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,EAAE,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACnE,CAAC;IAKD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,EAAE;YACnC,OAAO,KAA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