@pulumi/command 0.0.1-alpha.100
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/LICENSE +202 -0
- package/README.md +400 -0
- package/index.d.ts +7 -0
- package/index.js +26 -0
- package/index.js.map +1 -0
- package/local/command.d.ts +404 -0
- package/local/command.js +164 -0
- package/local/command.js.map +1 -0
- package/local/index.d.ts +7 -0
- package/local/index.js +41 -0
- package/local/index.js.map +1 -0
- package/local/run.d.ts +391 -0
- package/local/run.js +46 -0
- package/local/run.js.map +1 -0
- package/package.json +29 -0
- package/package.json.dev +28 -0
- package/provider.d.ts +21 -0
- package/provider.js +38 -0
- package/provider.js.map +1 -0
- package/remote/command.d.ts +206 -0
- package/remote/command.js +141 -0
- package/remote/command.js.map +1 -0
- package/remote/copyFile.d.ts +70 -0
- package/remote/copyFile.js +79 -0
- package/remote/copyFile.js.map +1 -0
- package/remote/copyToRemote.d.ts +125 -0
- package/remote/copyToRemote.js +134 -0
- package/remote/copyToRemote.js.map +1 -0
- package/remote/index.d.ts +10 -0
- package/remote/index.js +46 -0
- package/remote/index.js.map +1 -0
- package/scripts/install-pulumi-plugin.js +21 -0
- package/types/enums/index.d.ts +3 -0
- package/types/enums/index.js +11 -0
- package/types/enums/index.js.map +1 -0
- package/types/enums/local/index.d.ts +19 -0
- package/types/enums/local/index.js +24 -0
- package/types/enums/local/index.js.map +1 -0
- package/types/enums/remote/index.d.ts +19 -0
- package/types/enums/remote/index.js +24 -0
- package/types/enums/remote/index.js.map +1 -0
- package/types/index.d.ts +4 -0
- package/types/index.js +13 -0
- package/types/index.js.map +1 -0
- package/types/input.d.ts +98 -0
- package/types/input.js +27 -0
- package/types/input.js.map +1 -0
- package/types/output.d.ts +97 -0
- package/types/output.js +26 -0
- package/types/output.js.map +1 -0
- package/utilities.d.ts +8 -0
- package/utilities.js +101 -0
- package/utilities.js.map +1 -0
package/local/run.d.ts
ADDED
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as enums from "../types/enums";
|
|
3
|
+
/**
|
|
4
|
+
* A local command to be executed.
|
|
5
|
+
* This command will always be run on any preview or deployment. Use `local.Command` to avoid duplicating executions.
|
|
6
|
+
*/
|
|
7
|
+
export declare function run(args: RunArgs, opts?: pulumi.InvokeOptions): Promise<RunResult>;
|
|
8
|
+
export interface RunArgs {
|
|
9
|
+
/**
|
|
10
|
+
* If the previous command's stdout and stderr (as generated by the prior create/update) is
|
|
11
|
+
* injected into the environment of the next run as PULUMI_COMMAND_STDOUT and PULUMI_COMMAND_STDERR.
|
|
12
|
+
* Defaults to true.
|
|
13
|
+
*/
|
|
14
|
+
addPreviousOutputInEnv?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* A list of path globs to return as a single archive asset after the command completes.
|
|
17
|
+
*
|
|
18
|
+
* When specifying glob patterns the following rules apply:
|
|
19
|
+
* - We only include files not directories for assets and archives.
|
|
20
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
21
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
22
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
23
|
+
* - `*` matches anything except `/`
|
|
24
|
+
* - `**` matches anything, _including_ `/`
|
|
25
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
26
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
27
|
+
*
|
|
28
|
+
* #### Example
|
|
29
|
+
*
|
|
30
|
+
* Given the rules:
|
|
31
|
+
* ```yaml
|
|
32
|
+
* - "assets/**"
|
|
33
|
+
* - "src/**.js"
|
|
34
|
+
* - "!**secret.*"
|
|
35
|
+
* ```
|
|
36
|
+
*
|
|
37
|
+
* When evaluating against this folder:
|
|
38
|
+
*
|
|
39
|
+
* ```yaml
|
|
40
|
+
* - assets/
|
|
41
|
+
* - logos/
|
|
42
|
+
* - logo.svg
|
|
43
|
+
* - src/
|
|
44
|
+
* - index.js
|
|
45
|
+
* - secret.js
|
|
46
|
+
* ```
|
|
47
|
+
*
|
|
48
|
+
* The following paths will be returned:
|
|
49
|
+
*
|
|
50
|
+
* ```yaml
|
|
51
|
+
* - assets/logos/logo.svg
|
|
52
|
+
* - src/index.js
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
archivePaths?: string[];
|
|
56
|
+
/**
|
|
57
|
+
* A list of path globs to read after the command completes.
|
|
58
|
+
*
|
|
59
|
+
* When specifying glob patterns the following rules apply:
|
|
60
|
+
* - We only include files not directories for assets and archives.
|
|
61
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
62
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
63
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
64
|
+
* - `*` matches anything except `/`
|
|
65
|
+
* - `**` matches anything, _including_ `/`
|
|
66
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
67
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
68
|
+
*
|
|
69
|
+
* #### Example
|
|
70
|
+
*
|
|
71
|
+
* Given the rules:
|
|
72
|
+
* ```yaml
|
|
73
|
+
* - "assets/**"
|
|
74
|
+
* - "src/**.js"
|
|
75
|
+
* - "!**secret.*"
|
|
76
|
+
* ```
|
|
77
|
+
*
|
|
78
|
+
* When evaluating against this folder:
|
|
79
|
+
*
|
|
80
|
+
* ```yaml
|
|
81
|
+
* - assets/
|
|
82
|
+
* - logos/
|
|
83
|
+
* - logo.svg
|
|
84
|
+
* - src/
|
|
85
|
+
* - index.js
|
|
86
|
+
* - secret.js
|
|
87
|
+
* ```
|
|
88
|
+
*
|
|
89
|
+
* The following paths will be returned:
|
|
90
|
+
*
|
|
91
|
+
* ```yaml
|
|
92
|
+
* - assets/logos/logo.svg
|
|
93
|
+
* - src/index.js
|
|
94
|
+
* ```
|
|
95
|
+
*/
|
|
96
|
+
assetPaths?: string[];
|
|
97
|
+
/**
|
|
98
|
+
* The command to run.
|
|
99
|
+
*/
|
|
100
|
+
command: string;
|
|
101
|
+
/**
|
|
102
|
+
* The directory from which to run the command from. If `dir` does not exist, then
|
|
103
|
+
* `Command` will fail.
|
|
104
|
+
*/
|
|
105
|
+
dir?: string;
|
|
106
|
+
/**
|
|
107
|
+
* Additional environment variables available to the command's process.
|
|
108
|
+
*/
|
|
109
|
+
environment?: {
|
|
110
|
+
[key: string]: string;
|
|
111
|
+
};
|
|
112
|
+
/**
|
|
113
|
+
* The program and arguments to run the command.
|
|
114
|
+
* On Linux and macOS, defaults to: `["/bin/sh", "-c"]`. On Windows, defaults to: `["cmd", "/C"]`
|
|
115
|
+
*/
|
|
116
|
+
interpreter?: string[];
|
|
117
|
+
/**
|
|
118
|
+
* If the command's stdout and stderr should be logged. This doesn't affect the capturing of
|
|
119
|
+
* stdout and stderr as outputs. If there might be secrets in the output, you can disable logging here and mark the
|
|
120
|
+
* outputs as secret via 'additionalSecretOutputs'. Defaults to logging both stdout and stderr.
|
|
121
|
+
*/
|
|
122
|
+
logging?: enums.local.Logging;
|
|
123
|
+
/**
|
|
124
|
+
* Pass a string to the command's process as standard in
|
|
125
|
+
*/
|
|
126
|
+
stdin?: string;
|
|
127
|
+
}
|
|
128
|
+
export interface RunResult {
|
|
129
|
+
/**
|
|
130
|
+
* If the previous command's stdout and stderr (as generated by the prior create/update) is
|
|
131
|
+
* injected into the environment of the next run as PULUMI_COMMAND_STDOUT and PULUMI_COMMAND_STDERR.
|
|
132
|
+
* Defaults to true.
|
|
133
|
+
*/
|
|
134
|
+
readonly addPreviousOutputInEnv?: boolean;
|
|
135
|
+
/**
|
|
136
|
+
* An archive asset containing files found after running the command.
|
|
137
|
+
*/
|
|
138
|
+
readonly archive?: pulumi.asset.Archive;
|
|
139
|
+
/**
|
|
140
|
+
* A list of path globs to return as a single archive asset after the command completes.
|
|
141
|
+
*
|
|
142
|
+
* When specifying glob patterns the following rules apply:
|
|
143
|
+
* - We only include files not directories for assets and archives.
|
|
144
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
145
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
146
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
147
|
+
* - `*` matches anything except `/`
|
|
148
|
+
* - `**` matches anything, _including_ `/`
|
|
149
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
150
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
151
|
+
*
|
|
152
|
+
* #### Example
|
|
153
|
+
*
|
|
154
|
+
* Given the rules:
|
|
155
|
+
* ```yaml
|
|
156
|
+
* - "assets/**"
|
|
157
|
+
* - "src/**.js"
|
|
158
|
+
* - "!**secret.*"
|
|
159
|
+
* ```
|
|
160
|
+
*
|
|
161
|
+
* When evaluating against this folder:
|
|
162
|
+
*
|
|
163
|
+
* ```yaml
|
|
164
|
+
* - assets/
|
|
165
|
+
* - logos/
|
|
166
|
+
* - logo.svg
|
|
167
|
+
* - src/
|
|
168
|
+
* - index.js
|
|
169
|
+
* - secret.js
|
|
170
|
+
* ```
|
|
171
|
+
*
|
|
172
|
+
* The following paths will be returned:
|
|
173
|
+
*
|
|
174
|
+
* ```yaml
|
|
175
|
+
* - assets/logos/logo.svg
|
|
176
|
+
* - src/index.js
|
|
177
|
+
* ```
|
|
178
|
+
*/
|
|
179
|
+
readonly archivePaths?: string[];
|
|
180
|
+
/**
|
|
181
|
+
* A list of path globs to read after the command completes.
|
|
182
|
+
*
|
|
183
|
+
* When specifying glob patterns the following rules apply:
|
|
184
|
+
* - We only include files not directories for assets and archives.
|
|
185
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
186
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
187
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
188
|
+
* - `*` matches anything except `/`
|
|
189
|
+
* - `**` matches anything, _including_ `/`
|
|
190
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
191
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
192
|
+
*
|
|
193
|
+
* #### Example
|
|
194
|
+
*
|
|
195
|
+
* Given the rules:
|
|
196
|
+
* ```yaml
|
|
197
|
+
* - "assets/**"
|
|
198
|
+
* - "src/**.js"
|
|
199
|
+
* - "!**secret.*"
|
|
200
|
+
* ```
|
|
201
|
+
*
|
|
202
|
+
* When evaluating against this folder:
|
|
203
|
+
*
|
|
204
|
+
* ```yaml
|
|
205
|
+
* - assets/
|
|
206
|
+
* - logos/
|
|
207
|
+
* - logo.svg
|
|
208
|
+
* - src/
|
|
209
|
+
* - index.js
|
|
210
|
+
* - secret.js
|
|
211
|
+
* ```
|
|
212
|
+
*
|
|
213
|
+
* The following paths will be returned:
|
|
214
|
+
*
|
|
215
|
+
* ```yaml
|
|
216
|
+
* - assets/logos/logo.svg
|
|
217
|
+
* - src/index.js
|
|
218
|
+
* ```
|
|
219
|
+
*/
|
|
220
|
+
readonly assetPaths?: string[];
|
|
221
|
+
/**
|
|
222
|
+
* A map of assets found after running the command.
|
|
223
|
+
* The key is the relative path from the command dir
|
|
224
|
+
*/
|
|
225
|
+
readonly assets?: {
|
|
226
|
+
[key: string]: pulumi.asset.Asset | pulumi.asset.Archive;
|
|
227
|
+
};
|
|
228
|
+
/**
|
|
229
|
+
* The command to run.
|
|
230
|
+
*/
|
|
231
|
+
readonly command: string;
|
|
232
|
+
/**
|
|
233
|
+
* The directory from which to run the command from. If `dir` does not exist, then
|
|
234
|
+
* `Command` will fail.
|
|
235
|
+
*/
|
|
236
|
+
readonly dir?: string;
|
|
237
|
+
/**
|
|
238
|
+
* Additional environment variables available to the command's process.
|
|
239
|
+
*/
|
|
240
|
+
readonly environment?: {
|
|
241
|
+
[key: string]: string;
|
|
242
|
+
};
|
|
243
|
+
/**
|
|
244
|
+
* The program and arguments to run the command.
|
|
245
|
+
* On Linux and macOS, defaults to: `["/bin/sh", "-c"]`. On Windows, defaults to: `["cmd", "/C"]`
|
|
246
|
+
*/
|
|
247
|
+
readonly interpreter?: string[];
|
|
248
|
+
/**
|
|
249
|
+
* If the command's stdout and stderr should be logged. This doesn't affect the capturing of
|
|
250
|
+
* stdout and stderr as outputs. If there might be secrets in the output, you can disable logging here and mark the
|
|
251
|
+
* outputs as secret via 'additionalSecretOutputs'. Defaults to logging both stdout and stderr.
|
|
252
|
+
*/
|
|
253
|
+
readonly logging?: enums.local.Logging;
|
|
254
|
+
/**
|
|
255
|
+
* The standard error of the command's process
|
|
256
|
+
*/
|
|
257
|
+
readonly stderr: string;
|
|
258
|
+
/**
|
|
259
|
+
* Pass a string to the command's process as standard in
|
|
260
|
+
*/
|
|
261
|
+
readonly stdin?: string;
|
|
262
|
+
/**
|
|
263
|
+
* The standard output of the command's process
|
|
264
|
+
*/
|
|
265
|
+
readonly stdout: string;
|
|
266
|
+
}
|
|
267
|
+
/**
|
|
268
|
+
* A local command to be executed.
|
|
269
|
+
* This command will always be run on any preview or deployment. Use `local.Command` to avoid duplicating executions.
|
|
270
|
+
*/
|
|
271
|
+
export declare function runOutput(args: RunOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<RunResult>;
|
|
272
|
+
export interface RunOutputArgs {
|
|
273
|
+
/**
|
|
274
|
+
* If the previous command's stdout and stderr (as generated by the prior create/update) is
|
|
275
|
+
* injected into the environment of the next run as PULUMI_COMMAND_STDOUT and PULUMI_COMMAND_STDERR.
|
|
276
|
+
* Defaults to true.
|
|
277
|
+
*/
|
|
278
|
+
addPreviousOutputInEnv?: pulumi.Input<boolean>;
|
|
279
|
+
/**
|
|
280
|
+
* A list of path globs to return as a single archive asset after the command completes.
|
|
281
|
+
*
|
|
282
|
+
* When specifying glob patterns the following rules apply:
|
|
283
|
+
* - We only include files not directories for assets and archives.
|
|
284
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
285
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
286
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
287
|
+
* - `*` matches anything except `/`
|
|
288
|
+
* - `**` matches anything, _including_ `/`
|
|
289
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
290
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
291
|
+
*
|
|
292
|
+
* #### Example
|
|
293
|
+
*
|
|
294
|
+
* Given the rules:
|
|
295
|
+
* ```yaml
|
|
296
|
+
* - "assets/**"
|
|
297
|
+
* - "src/**.js"
|
|
298
|
+
* - "!**secret.*"
|
|
299
|
+
* ```
|
|
300
|
+
*
|
|
301
|
+
* When evaluating against this folder:
|
|
302
|
+
*
|
|
303
|
+
* ```yaml
|
|
304
|
+
* - assets/
|
|
305
|
+
* - logos/
|
|
306
|
+
* - logo.svg
|
|
307
|
+
* - src/
|
|
308
|
+
* - index.js
|
|
309
|
+
* - secret.js
|
|
310
|
+
* ```
|
|
311
|
+
*
|
|
312
|
+
* The following paths will be returned:
|
|
313
|
+
*
|
|
314
|
+
* ```yaml
|
|
315
|
+
* - assets/logos/logo.svg
|
|
316
|
+
* - src/index.js
|
|
317
|
+
* ```
|
|
318
|
+
*/
|
|
319
|
+
archivePaths?: pulumi.Input<pulumi.Input<string>[]>;
|
|
320
|
+
/**
|
|
321
|
+
* A list of path globs to read after the command completes.
|
|
322
|
+
*
|
|
323
|
+
* When specifying glob patterns the following rules apply:
|
|
324
|
+
* - We only include files not directories for assets and archives.
|
|
325
|
+
* - Path separators are `/` on all platforms - including Windows.
|
|
326
|
+
* - Patterns starting with `!` are 'exclude' rules.
|
|
327
|
+
* - Rules are evaluated in order, so exclude rules should be after inclusion rules.
|
|
328
|
+
* - `*` matches anything except `/`
|
|
329
|
+
* - `**` matches anything, _including_ `/`
|
|
330
|
+
* - All returned paths are relative to the working directory (without leading `./`) e.g. `file.text` or `subfolder/file.txt`.
|
|
331
|
+
* - For full details of the globbing syntax, see [github.com/gobwas/glob](https://github.com/gobwas/glob)
|
|
332
|
+
*
|
|
333
|
+
* #### Example
|
|
334
|
+
*
|
|
335
|
+
* Given the rules:
|
|
336
|
+
* ```yaml
|
|
337
|
+
* - "assets/**"
|
|
338
|
+
* - "src/**.js"
|
|
339
|
+
* - "!**secret.*"
|
|
340
|
+
* ```
|
|
341
|
+
*
|
|
342
|
+
* When evaluating against this folder:
|
|
343
|
+
*
|
|
344
|
+
* ```yaml
|
|
345
|
+
* - assets/
|
|
346
|
+
* - logos/
|
|
347
|
+
* - logo.svg
|
|
348
|
+
* - src/
|
|
349
|
+
* - index.js
|
|
350
|
+
* - secret.js
|
|
351
|
+
* ```
|
|
352
|
+
*
|
|
353
|
+
* The following paths will be returned:
|
|
354
|
+
*
|
|
355
|
+
* ```yaml
|
|
356
|
+
* - assets/logos/logo.svg
|
|
357
|
+
* - src/index.js
|
|
358
|
+
* ```
|
|
359
|
+
*/
|
|
360
|
+
assetPaths?: pulumi.Input<pulumi.Input<string>[]>;
|
|
361
|
+
/**
|
|
362
|
+
* The command to run.
|
|
363
|
+
*/
|
|
364
|
+
command: pulumi.Input<string>;
|
|
365
|
+
/**
|
|
366
|
+
* The directory from which to run the command from. If `dir` does not exist, then
|
|
367
|
+
* `Command` will fail.
|
|
368
|
+
*/
|
|
369
|
+
dir?: pulumi.Input<string>;
|
|
370
|
+
/**
|
|
371
|
+
* Additional environment variables available to the command's process.
|
|
372
|
+
*/
|
|
373
|
+
environment?: pulumi.Input<{
|
|
374
|
+
[key: string]: pulumi.Input<string>;
|
|
375
|
+
}>;
|
|
376
|
+
/**
|
|
377
|
+
* The program and arguments to run the command.
|
|
378
|
+
* On Linux and macOS, defaults to: `["/bin/sh", "-c"]`. On Windows, defaults to: `["cmd", "/C"]`
|
|
379
|
+
*/
|
|
380
|
+
interpreter?: pulumi.Input<pulumi.Input<string>[]>;
|
|
381
|
+
/**
|
|
382
|
+
* If the command's stdout and stderr should be logged. This doesn't affect the capturing of
|
|
383
|
+
* stdout and stderr as outputs. If there might be secrets in the output, you can disable logging here and mark the
|
|
384
|
+
* outputs as secret via 'additionalSecretOutputs'. Defaults to logging both stdout and stderr.
|
|
385
|
+
*/
|
|
386
|
+
logging?: pulumi.Input<enums.local.Logging>;
|
|
387
|
+
/**
|
|
388
|
+
* Pass a string to the command's process as standard in
|
|
389
|
+
*/
|
|
390
|
+
stdin?: pulumi.Input<string>;
|
|
391
|
+
}
|
package/local/run.js
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
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.runOutput = exports.run = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("../utilities");
|
|
8
|
+
/**
|
|
9
|
+
* A local command to be executed.
|
|
10
|
+
* This command will always be run on any preview or deployment. Use `local.Command` to avoid duplicating executions.
|
|
11
|
+
*/
|
|
12
|
+
function run(args, opts) {
|
|
13
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
|
|
14
|
+
return pulumi.runtime.invoke("command:local:run", {
|
|
15
|
+
"addPreviousOutputInEnv": args.addPreviousOutputInEnv,
|
|
16
|
+
"archivePaths": args.archivePaths,
|
|
17
|
+
"assetPaths": args.assetPaths,
|
|
18
|
+
"command": args.command,
|
|
19
|
+
"dir": args.dir,
|
|
20
|
+
"environment": args.environment,
|
|
21
|
+
"interpreter": args.interpreter,
|
|
22
|
+
"logging": args.logging,
|
|
23
|
+
"stdin": args.stdin,
|
|
24
|
+
}, opts);
|
|
25
|
+
}
|
|
26
|
+
exports.run = run;
|
|
27
|
+
/**
|
|
28
|
+
* A local command to be executed.
|
|
29
|
+
* This command will always be run on any preview or deployment. Use `local.Command` to avoid duplicating executions.
|
|
30
|
+
*/
|
|
31
|
+
function runOutput(args, opts) {
|
|
32
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
|
|
33
|
+
return pulumi.runtime.invokeOutput("command:local:run", {
|
|
34
|
+
"addPreviousOutputInEnv": args.addPreviousOutputInEnv,
|
|
35
|
+
"archivePaths": args.archivePaths,
|
|
36
|
+
"assetPaths": args.assetPaths,
|
|
37
|
+
"command": args.command,
|
|
38
|
+
"dir": args.dir,
|
|
39
|
+
"environment": args.environment,
|
|
40
|
+
"interpreter": args.interpreter,
|
|
41
|
+
"logging": args.logging,
|
|
42
|
+
"stdin": args.stdin,
|
|
43
|
+
}, opts);
|
|
44
|
+
}
|
|
45
|
+
exports.runOutput = runOutput;
|
|
46
|
+
//# sourceMappingURL=run.js.map
|
package/local/run.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run.js","sourceRoot":"","sources":["../../local/run.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AAIzC,0CAA0C;AAE1C;;;GAGG;AACH,SAAgB,GAAG,CAAC,IAAa,EAAE,IAA2B;IAC1D,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,mBAAmB,EAAE;QAC9C,wBAAwB,EAAE,IAAI,CAAC,sBAAsB;QACrD,cAAc,EAAE,IAAI,CAAC,YAAY;QACjC,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,SAAS,EAAE,IAAI,CAAC,OAAO;QACvB,KAAK,EAAE,IAAI,CAAC,GAAG;QACf,aAAa,EAAE,IAAI,CAAC,WAAW;QAC/B,aAAa,EAAE,IAAI,CAAC,WAAW;QAC/B,SAAS,EAAE,IAAI,CAAC,OAAO;QACvB,OAAO,EAAE,IAAI,CAAC,KAAK;KACtB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAbD,kBAaC;AAgQD;;;GAGG;AACH,SAAgB,SAAS,CAAC,IAAmB,EAAE,IAAiC;IAC5E,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,mBAAmB,EAAE;QACpD,wBAAwB,EAAE,IAAI,CAAC,sBAAsB;QACrD,cAAc,EAAE,IAAI,CAAC,YAAY;QACjC,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,SAAS,EAAE,IAAI,CAAC,OAAO;QACvB,KAAK,EAAE,IAAI,CAAC,GAAG;QACf,aAAa,EAAE,IAAI,CAAC,WAAW;QAC/B,aAAa,EAAE,IAAI,CAAC,WAAW;QAC/B,SAAS,EAAE,IAAI,CAAC,OAAO;QACvB,OAAO,EAAE,IAAI,CAAC,KAAK;KACtB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAbD,8BAaC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@pulumi/command",
|
|
3
|
+
"version": "0.0.1-alpha.100",
|
|
4
|
+
"keywords": [
|
|
5
|
+
"pulumi",
|
|
6
|
+
"command",
|
|
7
|
+
"category/utility",
|
|
8
|
+
"kind/native"
|
|
9
|
+
],
|
|
10
|
+
"homepage": "https://pulumi.com",
|
|
11
|
+
"repository": "https://github.com/pulumi/pulumi-command",
|
|
12
|
+
"license": "Apache-2.0",
|
|
13
|
+
"scripts": {
|
|
14
|
+
"build": "tsc",
|
|
15
|
+
"install": "node scripts/install-pulumi-plugin.js resource command 0.0.1-alpha.100"
|
|
16
|
+
},
|
|
17
|
+
"dependencies": {
|
|
18
|
+
"@pulumi/pulumi": "^3.136.0"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"@types/node": "^14",
|
|
22
|
+
"typescript": "^4.3.5"
|
|
23
|
+
},
|
|
24
|
+
"pulumi": {
|
|
25
|
+
"resource": true,
|
|
26
|
+
"name": "command",
|
|
27
|
+
"version": "0.0.1-alpha.100"
|
|
28
|
+
}
|
|
29
|
+
}
|
package/package.json.dev
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@pulumi/command",
|
|
3
|
+
"version": "0.0.1-alpha.100",
|
|
4
|
+
"keywords": [
|
|
5
|
+
"pulumi",
|
|
6
|
+
"command",
|
|
7
|
+
"category/utility",
|
|
8
|
+
"kind/native"
|
|
9
|
+
],
|
|
10
|
+
"homepage": "https://pulumi.com",
|
|
11
|
+
"repository": "https://github.com/pulumi/pulumi-command",
|
|
12
|
+
"license": "Apache-2.0",
|
|
13
|
+
"scripts": {
|
|
14
|
+
"build": "tsc"
|
|
15
|
+
},
|
|
16
|
+
"dependencies": {
|
|
17
|
+
"@pulumi/pulumi": "^3.136.0"
|
|
18
|
+
},
|
|
19
|
+
"devDependencies": {
|
|
20
|
+
"@types/node": "^14",
|
|
21
|
+
"typescript": "^4.3.5"
|
|
22
|
+
},
|
|
23
|
+
"pulumi": {
|
|
24
|
+
"resource": true,
|
|
25
|
+
"name": "command",
|
|
26
|
+
"version": "0.0.1-alpha.100"
|
|
27
|
+
}
|
|
28
|
+
}
|
package/provider.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
export declare class Provider extends pulumi.ProviderResource {
|
|
3
|
+
/**
|
|
4
|
+
* Returns true if the given object is an instance of Provider. This is designed to work even
|
|
5
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
6
|
+
*/
|
|
7
|
+
static isInstance(obj: any): obj is Provider;
|
|
8
|
+
/**
|
|
9
|
+
* Create a Provider resource with the given unique name, arguments, and options.
|
|
10
|
+
*
|
|
11
|
+
* @param name The _unique_ name of the resource.
|
|
12
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
13
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
14
|
+
*/
|
|
15
|
+
constructor(name: string, args?: ProviderArgs, opts?: pulumi.ResourceOptions);
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The set of arguments for constructing a Provider resource.
|
|
19
|
+
*/
|
|
20
|
+
export interface ProviderArgs {
|
|
21
|
+
}
|
package/provider.js
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
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.Provider = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("./utilities");
|
|
8
|
+
class Provider extends pulumi.ProviderResource {
|
|
9
|
+
/**
|
|
10
|
+
* Returns true if the given object is an instance of Provider. This is designed to work even
|
|
11
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
12
|
+
*/
|
|
13
|
+
static isInstance(obj) {
|
|
14
|
+
if (obj === undefined || obj === null) {
|
|
15
|
+
return false;
|
|
16
|
+
}
|
|
17
|
+
return obj['__pulumiType'] === "pulumi:providers:" + Provider.__pulumiType;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Create a Provider resource with the given unique name, arguments, and options.
|
|
21
|
+
*
|
|
22
|
+
* @param name The _unique_ name of the resource.
|
|
23
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
24
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
25
|
+
*/
|
|
26
|
+
constructor(name, args, opts) {
|
|
27
|
+
let resourceInputs = {};
|
|
28
|
+
opts = opts || {};
|
|
29
|
+
{
|
|
30
|
+
}
|
|
31
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
32
|
+
super(Provider.__pulumiType, name, resourceInputs, opts);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
exports.Provider = Provider;
|
|
36
|
+
/** @internal */
|
|
37
|
+
Provider.__pulumiType = 'command';
|
|
38
|
+
//# sourceMappingURL=provider.js.map
|
package/provider.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"provider.js","sourceRoot":"","sources":["../provider.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC,MAAa,QAAS,SAAQ,MAAM,CAAC,gBAAgB;IAIjD;;;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,GAAG,QAAQ,CAAC,YAAY,CAAC;IAC/E,CAAC;IAGD;;;;;;OAMG;IACH,YAAY,IAAY,EAAE,IAAmB,EAAE,IAA6B;QACxE,IAAI,cAAc,GAAkB,EAAE,CAAC;QACvC,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAClB;SACC;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,QAAQ,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IAC7D,CAAC;;AA9BL,4BA+BC;AA9BG,gBAAgB;AACO,qBAAY,GAAG,SAAS,CAAC"}
|