@storm-software/pulumi-tools 0.7.80 → 0.7.82

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 (58) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/README.md +1 -2
  3. package/dist/chunk-2PVTUX4W.mjs +133 -0
  4. package/dist/{chunk-GZGV3XVE.js → chunk-2QARL2O5.js} +2 -2
  5. package/dist/{chunk-2RIB3KMO.mjs → chunk-2TYNPYBU.mjs} +1 -1
  6. package/dist/chunk-36ZCRXV6.mjs +18 -0
  7. package/dist/chunk-3RG5ZIWI.js +10 -0
  8. package/dist/chunk-DFUGKUEV.js +42 -0
  9. package/dist/{chunk-DWS257B5.mjs → chunk-DIIDXD4R.mjs} +1 -1
  10. package/dist/chunk-E5AP6CDG.mjs +16 -0
  11. package/dist/{chunk-DBLK3NPE.js → chunk-HUKXHFCA.js} +4 -9
  12. package/dist/{chunk-WPRKDCZP.mjs → chunk-IEZKYJSF.mjs} +3 -6
  13. package/dist/{chunk-2UN5QH5X.mjs → chunk-IWIZJWH3.mjs} +1196 -826
  14. package/dist/{chunk-RHKA2SRN.mjs → chunk-KPFHCT4A.mjs} +3 -8
  15. package/dist/chunk-N7ZQU3A6.js +16 -0
  16. package/dist/{chunk-I3FRKBMS.js → chunk-O2YJQKYB.js} +2 -2
  17. package/dist/{chunk-AKO3NFBS.js → chunk-R3EJZLX2.js} +1197 -827
  18. package/dist/{chunk-QNQZE4KJ.js → chunk-RWNDPKJK.js} +2 -2
  19. package/dist/{chunk-RIBEILOQ.mjs → chunk-SSY3QNGM.mjs} +1 -1
  20. package/dist/chunk-T6O7JL6L.mjs +42 -0
  21. package/dist/chunk-TXKOR3ID.js +18 -0
  22. package/dist/chunk-ZUJ3PY3K.js +133 -0
  23. package/dist/executors.js +8 -8
  24. package/dist/executors.mjs +8 -8
  25. package/dist/generators.js +5 -5
  26. package/dist/generators.mjs +4 -4
  27. package/dist/index.js +11 -11
  28. package/dist/index.mjs +10 -10
  29. package/dist/src/base/base-executor.js +4 -4
  30. package/dist/src/base/base-executor.mjs +3 -3
  31. package/dist/src/base/index.js +5 -5
  32. package/dist/src/base/index.mjs +4 -4
  33. package/dist/src/base/providers.js +3 -3
  34. package/dist/src/base/providers.mjs +2 -2
  35. package/dist/src/executors/config/executor.js +5 -5
  36. package/dist/src/executors/config/executor.mjs +4 -4
  37. package/dist/src/executors/import/executor.js +5 -5
  38. package/dist/src/executors/import/executor.mjs +4 -4
  39. package/dist/src/executors/preview/executor.js +5 -5
  40. package/dist/src/executors/preview/executor.mjs +4 -4
  41. package/dist/src/executors/refresh/executor.js +5 -5
  42. package/dist/src/executors/refresh/executor.mjs +4 -4
  43. package/dist/src/executors/up/executor.js +5 -5
  44. package/dist/src/executors/up/executor.mjs +4 -4
  45. package/dist/src/generators/init/generator.js +5 -5
  46. package/dist/src/generators/init/generator.mjs +4 -4
  47. package/dist/tsup.config.js +3 -8
  48. package/dist/tsup.config.mjs +3 -8
  49. package/package.json +1 -1
  50. package/dist/chunk-2FBBYFXH.js +0 -15
  51. package/dist/chunk-3GQAWCBQ.js +0 -13
  52. package/dist/chunk-A6G6LISR.js +0 -109
  53. package/dist/chunk-BSF4KVL2.mjs +0 -15
  54. package/dist/chunk-EDEA6SLS.mjs +0 -13
  55. package/dist/chunk-P47FZNOX.js +0 -35
  56. package/dist/chunk-QXOPKCW2.mjs +0 -35
  57. package/dist/chunk-TEUUTJBW.mjs +0 -109
  58. package/dist/chunk-UV2ERO6Z.js +0 -13
package/CHANGELOG.md CHANGED
@@ -2,6 +2,27 @@
2
2
 
3
3
  # Changelog for Storm Ops - Pulumi Tools
4
4
 
5
+ ## [0.7.82](https://github.com/storm-software/storm-ops/releases/tag/pulumi-tools%400.7.82) (2025-04-30)
6
+
7
+ ### Miscellaneous
8
+
9
+ - **esbuild:** Remove swc plugin for ESBuild
10
+ ([ad298c288](https://github.com/storm-software/storm-ops/commit/ad298c288))
11
+ - **monorepo:** Regenerate README markdown files
12
+ ([933d45f0b](https://github.com/storm-software/storm-ops/commit/933d45f0b))
13
+
14
+ ## [0.7.81](https://github.com/storm-software/storm-ops/releases/tag/pulumi-tools%400.7.81) (2025-04-30)
15
+
16
+ ### Bug Fixes
17
+
18
+ - **esbuild:** Update script to use .cjs file extension
19
+ ([95c4e5abd](https://github.com/storm-software/storm-ops/commit/95c4e5abd))
20
+
21
+ ### Miscellaneous
22
+
23
+ - **monorepo:** Regenerate README markdown files
24
+ ([17b6c5930](https://github.com/storm-software/storm-ops/commit/17b6c5930))
25
+
5
26
  ## [0.7.80](https://github.com/storm-software/storm-ops/releases/tag/pulumi-tools%400.7.80) (2025-04-30)
6
27
 
7
28
  ### Bug Fixes
package/README.md CHANGED
@@ -21,7 +21,7 @@ This package is part of the <b>⚡Storm-Ops</b> monorepo. The Storm-Ops packages
21
21
 
22
22
  <h3 align="center">💻 Visit <a href="https://stormsoftware.com" target="_blank">stormsoftware.com</a> to stay up to date with this developer</h3><br />
23
23
 
24
- [![Version](https://img.shields.io/badge/version-0.7.79-1fb2a6.svg?style=for-the-badge&color=1fb2a6)](https://prettier.io/)&nbsp;[![Nx](https://img.shields.io/badge/Nx-17.0.2-lightgrey?style=for-the-badge&logo=nx&logoWidth=20&&color=1fb2a6)](http://nx.dev/)&nbsp;[![NextJs](https://img.shields.io/badge/Next.js-14.0.2-lightgrey?style=for-the-badge&logo=nextdotjs&logoWidth=20&color=1fb2a6)](https://nextjs.org/)&nbsp;[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=for-the-badge&logo=commitlint&color=1fb2a6)](http://commitizen.github.io/cz-cli/)&nbsp;![Semantic-Release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg?style=for-the-badge&color=1fb2a6)&nbsp;[![documented with Fumadocs](https://img.shields.io/badge/documented_with-fumadocs-success.svg?style=for-the-badge&logo=readthedocs&color=1fb2a6)](https://fumadocs.vercel.app/)&nbsp;![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/storm-software/storm-ops/cr.yml?style=for-the-badge&logo=github-actions&color=1fb2a6)
24
+ [![Version](https://img.shields.io/badge/version-0.7.81-1fb2a6.svg?style=for-the-badge&color=1fb2a6)](https://prettier.io/)&nbsp;[![Nx](https://img.shields.io/badge/Nx-17.0.2-lightgrey?style=for-the-badge&logo=nx&logoWidth=20&&color=1fb2a6)](http://nx.dev/)&nbsp;[![NextJs](https://img.shields.io/badge/Next.js-14.0.2-lightgrey?style=for-the-badge&logo=nextdotjs&logoWidth=20&color=1fb2a6)](https://nextjs.org/)&nbsp;[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=for-the-badge&logo=commitlint&color=1fb2a6)](http://commitizen.github.io/cz-cli/)&nbsp;![Semantic-Release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg?style=for-the-badge&color=1fb2a6)&nbsp;[![documented with Fumadocs](https://img.shields.io/badge/documented_with-fumadocs-success.svg?style=for-the-badge&logo=readthedocs&color=1fb2a6)](https://fumadocs.vercel.app/)&nbsp;![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/storm-software/storm-ops/cr.yml?style=for-the-badge&logo=github-actions&color=1fb2a6)
25
25
 
26
26
  <!-- prettier-ignore-start -->
27
27
  <!-- markdownlint-disable -->
@@ -40,7 +40,6 @@ This package is part of the <b>⚡Storm-Ops</b> monorepo. The Storm-Ops packages
40
40
 
41
41
  <!-- START doctoc -->
42
42
  <!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
43
-
44
43
  ## Table of Contents
45
44
 
46
45
  - [Storm Pulumi Tools](#storm-pulumi-tools)
@@ -0,0 +1,133 @@
1
+ import {
2
+ getCloudTemplateName
3
+ } from "./chunk-KPFHCT4A.mjs";
4
+ import {
5
+ initGenerator,
6
+ run,
7
+ withRunGenerator
8
+ } from "./chunk-IWIZJWH3.mjs";
9
+
10
+ // src/generators/init/generator.ts
11
+ import {
12
+ addDependenciesToPackageJson,
13
+ addProjectConfiguration,
14
+ formatFiles,
15
+ readJsonFile,
16
+ runTasksInSerial
17
+ } from "@nx/devkit";
18
+ import { readFileSync, unlinkSync } from "node:fs";
19
+ import { join } from "node:path";
20
+ async function initGeneratorFn(tree, options, config) {
21
+ const task = initGenerator(tree, options);
22
+ addProjectConfiguration(tree, options.name || "deployment", {
23
+ root: options.directory || "./deployment",
24
+ projectType: "application",
25
+ sourceRoot: options.directory || "./deployment",
26
+ targets: {
27
+ up: {
28
+ executor: "@nx-extend/pulumi:up",
29
+ options: {}
30
+ },
31
+ preview: {
32
+ executor: "@nx-extend/pulumi:preview",
33
+ options: {}
34
+ },
35
+ refresh: {
36
+ executor: "@nx-extend/pulumi:refresh",
37
+ options: {}
38
+ },
39
+ import: {
40
+ executor: "@nx-extend/pulumi:import",
41
+ options: {}
42
+ }
43
+ },
44
+ tags: ["infra:pulumi"]
45
+ });
46
+ await runTasksInSerial(
47
+ generateNewPulumiProject(tree, options, config),
48
+ loginToPulumi(tree, options, config),
49
+ addPulumiDeps(tree, options),
50
+ cleanupProject(tree, options)
51
+ )();
52
+ if (!options.skipFormat) {
53
+ await formatFiles(tree);
54
+ }
55
+ return task;
56
+ }
57
+ var generator_default = withRunGenerator(
58
+ "Initialize Storm Pulumi workspace",
59
+ initGeneratorFn
60
+ );
61
+ function generateNewPulumiProject(tree, options, config) {
62
+ return () => {
63
+ const template = getCloudTemplateName(options.provider);
64
+ run(
65
+ config,
66
+ [
67
+ `pulumi new ${template}`,
68
+ `--name=${options.name || "deployment"}`,
69
+ `--dir=${options.directory || "./deployment"}`,
70
+ options.secretsProvider && `--secrets-provider=${options.secretsProvider}`,
71
+ "--generate-only",
72
+ "--yes",
73
+ "--force"
74
+ ].filter(Boolean).join(" "),
75
+ join(config.workspaceRoot, options.directory || "./deployment"),
76
+ "inherit"
77
+ );
78
+ };
79
+ }
80
+ function loginToPulumi(tree, options, config) {
81
+ return () => {
82
+ if (!options.login) {
83
+ return;
84
+ }
85
+ if (options.login.startsWith("file://")) {
86
+ options.login = `file://${tree.root}/${options.directory || "./deployment"}/${options.login.replace("file://", "")}`;
87
+ }
88
+ run(
89
+ config,
90
+ ["pulumi login", options.login].filter(Boolean).join(" "),
91
+ join(config.workspaceRoot, options.directory || "./deployment"),
92
+ "inherit",
93
+ {
94
+ ...process.env,
95
+ PULUMI_EXPERIMENTAL: "true"
96
+ }
97
+ );
98
+ };
99
+ }
100
+ function addPulumiDeps(tree, options) {
101
+ return () => {
102
+ const packageJson = readJsonFile(`${options.directory}/package.json`);
103
+ if (packageJson) {
104
+ addDependenciesToPackageJson(tree, {}, packageJson.dependencies || {})();
105
+ }
106
+ };
107
+ }
108
+ function cleanupProject(tree, options) {
109
+ return () => {
110
+ const indexTsLocation = join(
111
+ tree.root,
112
+ `${options.directory || "./deployment"}/index.ts`
113
+ );
114
+ tree.write(
115
+ `${options.directory}/pulumi.ts`,
116
+ readFileSync(indexTsLocation).toString()
117
+ );
118
+ unlinkSync(
119
+ join(tree.root, `${options.directory || "./deployment"}/.gitignore`)
120
+ );
121
+ unlinkSync(
122
+ join(tree.root, `${options.directory || "./deployment"}/package.json`)
123
+ );
124
+ unlinkSync(
125
+ join(tree.root, `${options.directory || "./deployment"}/tsconfig.json`)
126
+ );
127
+ };
128
+ }
129
+
130
+ export {
131
+ initGeneratorFn,
132
+ generator_default
133
+ };
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkP47FZNOXjs = require('./chunk-P47FZNOX.js');
3
+ var _chunkDFUGKUEVjs = require('./chunk-DFUGKUEV.js');
4
4
 
5
5
  // src/executors/up/executor.ts
6
- var executor_default = _chunkP47FZNOXjs.withPulumiExecutor.call(void 0, "up", (options) => [
6
+ var executor_default = _chunkDFUGKUEVjs.withPulumiExecutor.call(void 0, "up", (options) => [
7
7
  "--suppress-progress",
8
8
  options.stack && `--stack=${options.stack}`,
9
9
  options.skipPreview && "--skip-preview",
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  withPulumiExecutor
3
- } from "./chunk-QXOPKCW2.mjs";
3
+ } from "./chunk-T6O7JL6L.mjs";
4
4
 
5
5
  // src/executors/config/executor.ts
6
6
  var executor_default = withPulumiExecutor("config", (options) => [
@@ -0,0 +1,18 @@
1
+ import {
2
+ withPulumiExecutor
3
+ } from "./chunk-T6O7JL6L.mjs";
4
+
5
+ // src/executors/refresh/executor.ts
6
+ var executor_default = withPulumiExecutor(
7
+ "refresh",
8
+ (options) => [
9
+ "--suppress-progress",
10
+ options.stack && `--stack=${options.stack}`,
11
+ options.skipPreview && "--skip-preview",
12
+ options.yes && "--yes"
13
+ ]
14
+ );
15
+
16
+ export {
17
+ executor_default
18
+ };
@@ -0,0 +1,10 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
2
+ get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
3
+ }) : x)(function(x) {
4
+ if (typeof require !== "undefined") return require.apply(this, arguments);
5
+ throw Error('Dynamic require of "' + x + '" is not supported');
6
+ });
7
+
8
+
9
+
10
+ exports.__require = __require;
@@ -0,0 +1,42 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
+
3
+
4
+ var _chunkR3EJZLX2js = require('./chunk-R3EJZLX2.js');
5
+
6
+ // src/base/base-executor.ts
7
+ var _path = require('path');
8
+ var _shelljs = require('shelljs');
9
+ var withPulumiExecutor = (command, argsMapper, executorOptions = {}) => async (_options, context) => {
10
+ return _chunkR3EJZLX2js.withRunExecutor.call(void 0,
11
+ `Pulumi \`${command}\` Command Executor`,
12
+ async (options, context2, config) => {
13
+ if (!_shelljs.which.call(void 0, "pulumi")) {
14
+ throw new Error(
15
+ "Pulumi is not installed. Please install it before running this executor."
16
+ );
17
+ }
18
+ if (!_optionalChain([context2, 'access', _ => _.projectsConfigurations, 'optionalAccess', _2 => _2.projects]) || !context2.projectName || !context2.projectsConfigurations.projects[context2.projectName]) {
19
+ throw new Error(
20
+ "The Build process failed because the context is not valid. Please run this command from a workspace."
21
+ );
22
+ }
23
+ const { sourceRoot } = context2.projectsConfigurations.projects[context2.projectName];
24
+ _chunkR3EJZLX2js.run.call(void 0,
25
+ config,
26
+ ["pulumi", command, ...argsMapper(options)].filter(Boolean).join(" "),
27
+ _path.join.call(void 0, config.workspaceRoot, options.root || sourceRoot),
28
+ "inherit",
29
+ {
30
+ ...process.env,
31
+ PULUMI_EXPERIMENTAL: "true"
32
+ }
33
+ );
34
+ return null;
35
+ },
36
+ executorOptions
37
+ )(_options, context);
38
+ };
39
+
40
+
41
+
42
+ exports.withPulumiExecutor = withPulumiExecutor;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  withPulumiExecutor
3
- } from "./chunk-QXOPKCW2.mjs";
3
+ } from "./chunk-T6O7JL6L.mjs";
4
4
 
5
5
  // src/executors/import/executor.ts
6
6
  var executor_default = withPulumiExecutor("import", (options) => [
@@ -0,0 +1,16 @@
1
+ import {
2
+ withPulumiExecutor
3
+ } from "./chunk-T6O7JL6L.mjs";
4
+
5
+ // src/executors/preview/executor.ts
6
+ var executor_default = withPulumiExecutor(
7
+ "preview",
8
+ (options) => [
9
+ options.stack && `--stack=${options.stack}`,
10
+ options.expectNoChanges && "--expect-no-changes"
11
+ ]
12
+ );
13
+
14
+ export {
15
+ executor_default
16
+ };
@@ -1,18 +1,13 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunk3GQAWCBQjs = require('./chunk-3GQAWCBQ.js');
4
-
5
- // src/base/providers.ts
6
- var Provider;
7
- (function(Provider2) {
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/base/providers.ts
2
+ var Provider = /* @__PURE__ */ ((Provider2) => {
8
3
  Provider2["AWS"] = "aws";
9
4
  Provider2["AZURE"] = "azure";
10
5
  Provider2["GOOGLE_CLOUD_PLATFORM"] = "gcp";
11
- })(Provider || (Provider = exports.Provider = {}));
6
+ return Provider2;
7
+ })(Provider || {});
12
8
  function getCloudTemplateName(cloudProvider) {
13
9
  return `${cloudProvider}-typescript`;
14
10
  }
15
- _chunk3GQAWCBQjs.__name.call(void 0, getCloudTemplateName, "getCloudTemplateName");
16
11
 
17
12
 
18
13
 
@@ -1,5 +1,3 @@
1
- var __defProp = Object.defineProperty;
2
- var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
3
1
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
4
2
  get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
5
3
  }) : x)(function(x) {
@@ -7,15 +5,14 @@ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require
7
5
  throw Error('Dynamic require of "' + x + '" is not supported');
8
6
  });
9
7
 
10
- // ../../node_modules/.pnpm/tsup@8.4.0_patch_hash=f38aab44b872fc3814414c6a0e9d6e644f0efcadfc3a3eff3f293f7a0295534d__11c18a981686f6a33e045201f02415b6/node_modules/tsup/assets/esm_shims.js
8
+ // ../../node_modules/.pnpm/tsup@8.4.0_patch_hash=616d4d8468728c5caa25e7b97fe871f667b5342103b43bda8e891020bc6b674a__e7bfd10e92d28211ce978b182e37e925/node_modules/tsup/assets/esm_shims.js
11
9
  import { fileURLToPath } from "url";
12
10
  import path from "path";
13
- var getFilename = /* @__PURE__ */ __name(() => fileURLToPath(import.meta.url), "getFilename");
14
- var getDirname = /* @__PURE__ */ __name(() => path.dirname(getFilename()), "getDirname");
11
+ var getFilename = () => fileURLToPath(import.meta.url);
12
+ var getDirname = () => path.dirname(getFilename());
15
13
  var __dirname = /* @__PURE__ */ getDirname();
16
14
 
17
15
  export {
18
- __name,
19
16
  __require,
20
17
  __dirname
21
18
  };