skuba 9.0.0-main-20240918063050 → 9.0.0-main-20240928013837
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/config/eslint.js +1 -3
- package/lib/api/github/issueComment.js.map +2 -2
- package/lib/cli/adapter/eslint.d.ts +1 -1
- package/lib/cli/adapter/eslint.js +34 -8
- package/lib/cli/adapter/eslint.js.map +2 -2
- package/lib/cli/build/index.js +1 -0
- package/lib/cli/build/index.js.map +1 -1
- package/lib/cli/configure/modules/eslint.js +4 -8
- package/lib/cli/configure/modules/eslint.js.map +2 -2
- package/lib/cli/configure/processing/configFile.js +1 -1
- package/lib/cli/configure/processing/configFile.js.map +2 -2
- package/lib/cli/format.d.ts +1 -1
- package/lib/cli/format.js +2 -2
- package/lib/cli/format.js.map +2 -2
- package/lib/cli/init/getConfig.js.map +1 -1
- package/lib/cli/init/index.js +1 -1
- package/lib/cli/init/index.js.map +1 -1
- package/lib/cli/init/types.js.map +2 -2
- package/lib/cli/lint/autofix.d.ts +1 -0
- package/lib/cli/lint/autofix.js +2 -2
- package/lib/cli/lint/autofix.js.map +2 -2
- package/lib/cli/lint/eslint.d.ts +1 -1
- package/lib/cli/lint/eslint.js +1 -1
- package/lib/cli/lint/eslint.js.map +2 -2
- package/lib/cli/lint/internalLints/patchRenovateConfig.js +0 -4
- package/lib/cli/lint/internalLints/patchRenovateConfig.js.map +2 -2
- package/lib/cli/lint/internalLints/refreshConfigFiles.js +0 -1
- package/lib/cli/lint/internalLints/refreshConfigFiles.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/collapseDuplicateMergeKeys.d.ts +2 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/collapseDuplicateMergeKeys.js +90 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/collapseDuplicateMergeKeys.js.map +7 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/index.js +15 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/index.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerCompose.js +2 -4
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerCompose.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerImages.d.ts +2 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerImages.js +141 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerImages.js.map +7 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/upgradeESLint.d.ts +2 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/upgradeESLint.js +144 -0
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/upgradeESLint.js.map +7 -0
- package/lib/cli/lint/types.d.ts +4 -0
- package/lib/cli/lint/types.js.map +1 -1
- package/lib/eslint.d.js +2 -0
- package/lib/index.js.map +1 -1
- package/lib/skuba.js.map +1 -1
- package/lib/utils/copy.js +1 -1
- package/lib/utils/copy.js.map +2 -2
- package/lib/wrapper/main.js.map +1 -1
- package/lib/wrapper/requestListener.js.map +2 -2
- package/package.json +11 -10
- package/template/base/_eslint.config.js +1 -0
- package/template/express-rest-api/Dockerfile +1 -1
- package/template/express-rest-api/Dockerfile.dev-deps +1 -1
- package/template/express-rest-api/package.json +2 -2
- package/template/greeter/Dockerfile +1 -1
- package/template/greeter/package.json +2 -2
- package/template/koa-rest-api/Dockerfile +1 -1
- package/template/koa-rest-api/Dockerfile.dev-deps +1 -1
- package/template/koa-rest-api/package.json +3 -3
- package/template/koa-rest-api/src/framework/server.test.ts +2 -1
- package/template/lambda-sqs-worker/Dockerfile +1 -1
- package/template/lambda-sqs-worker/package.json +3 -3
- package/template/lambda-sqs-worker/src/types/jobScorer.ts +1 -1
- package/template/lambda-sqs-worker-cdk/Dockerfile +1 -1
- package/template/lambda-sqs-worker-cdk/infra/__snapshots__/appStack.test.ts.snap +12 -0
- package/template/lambda-sqs-worker-cdk/package.json +3 -3
- package/lib/why-is-node-running.d.js +0 -2
- package/template/base/_.eslintignore +0 -15
- package/template/base/_.eslintrc.js +0 -3
- /package/lib/{why-is-node-running.d.js.map → eslint.d.js.map} +0 -0
package/lib/cli/lint/types.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/cli/lint/types.ts"],
|
|
4
|
-
"sourcesContent": ["import type { Writable } from 'stream';\n\nexport interface Input {\n /**\n * Whether to enable verbose debug logging.\n *\n * Defaults to `false`.\n */\n debug: boolean;\n\n /**\n * Whether to disable parallelism to run linting operations serially.\n *\n * This can be useful for executing in resource-constrained environments and\n * snapshotting deterministic output in tests.\n *\n * Defaults to `false`.\n */\n serial: boolean;\n\n /**\n * An override output stream that can be supplied to test `tsc` logging.\n *\n * Defaults to `process.stdout`.\n */\n tscOutputStream?: Writable;\n\n /**\n * Whether to allow usage of Node.js worker threads.\n *\n * This may be set to `false` when there is a worker thread incompatibility,\n * such as calling in from a TypeScript context in our Jest tests.\n *\n * Defaults to `true`.\n */\n workerThreads?: boolean;\n}\n"],
|
|
4
|
+
"sourcesContent": ["import type { Writable } from 'stream';\n\nexport interface Input {\n /**\n * Whether to enable verbose debug logging.\n *\n * Defaults to `false`.\n */\n debug: boolean;\n\n /**\n * Whether to disable parallelism to run linting operations serially.\n *\n * This can be useful for executing in resource-constrained environments and\n * snapshotting deterministic output in tests.\n *\n * Defaults to `false`.\n */\n serial: boolean;\n\n /**\n * An override output stream that can be supplied to test `tsc` logging.\n *\n * Defaults to `process.stdout`.\n */\n tscOutputStream?: Writable;\n\n /**\n * Whether to allow usage of Node.js worker threads.\n *\n * This may be set to `false` when there is a worker thread incompatibility,\n * such as calling in from a TypeScript context in our Jest tests.\n *\n * Defaults to `true`.\n */\n workerThreads?: boolean;\n\n /**\n * An override to point to a specific ESLint config file.\n */\n eslintConfigFile?: string;\n}\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;AAAA;AAAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/lib/eslint.d.js
ADDED
package/lib/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/index.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * Entry point for the Node.js development API.\n *\n * This is where skuba imports point to:\n *\n * ```typescript\n * import { Net } from 'skuba';\n *\n * const { Net } = require('skuba');\n * ```\n */\n\nexport * as Buildkite from './api/buildkite';\nexport * as Git from './api/git';\nexport * as GitHub from './api/github';\nexport * as Jest from './api/jest';\nexport * as Net from './api/net';\n\n// evanw/esbuild#2388\ndeclare global {\n // eslint-disable-next-line @typescript-eslint/no-namespace\n namespace WebAssembly {\n // eslint-disable-next-line @typescript-eslint/no-empty-
|
|
4
|
+
"sourcesContent": ["/**\n * Entry point for the Node.js development API.\n *\n * This is where skuba imports point to:\n *\n * ```typescript\n * import { Net } from 'skuba';\n *\n * const { Net } = require('skuba');\n * ```\n */\n\nexport * as Buildkite from './api/buildkite';\nexport * as Git from './api/git';\nexport * as GitHub from './api/github';\nexport * as Jest from './api/jest';\nexport * as Net from './api/net';\n\n// evanw/esbuild#2388\ndeclare global {\n // eslint-disable-next-line @typescript-eslint/no-namespace\n namespace WebAssembly {\n // eslint-disable-next-line @typescript-eslint/no-empty-object-type\n interface Module {}\n }\n}\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAYA,gBAA2B;AAC3B,UAAqB;AACrB,aAAwB;AACxB,WAAsB;AACtB,UAAqB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/lib/skuba.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/skuba.ts"],
|
|
4
|
-
"sourcesContent": ["#!/usr/bin/env node\n\n/**\n * Entry point for the CLI.\n *\n * This is where you end up when you run:\n *\n * ```bash\n * [pnpm|yarn] skuba help\n * ```\n */\n\nimport path from 'path';\n\nimport { parseProcessArgs } from './utils/args';\nimport {\n COMMAND_DIR,\n COMMAND_SET,\n type Command,\n commandToModule,\n} from './utils/command';\nimport { isCiEnv } from './utils/env';\nimport { handleCliError } from './utils/error';\nimport { showHelp } from './utils/help';\nimport { log } from './utils/logging';\nimport { showLogoAndVersionInfo } from './utils/logo';\nimport { hasProp } from './utils/validation';\n\nconst THIRTY_MINUTES = 30 * 60 * 1000;\n\nconst skuba = async () => {\n const { commandName } = parseProcessArgs(process.argv);\n\n if (COMMAND_SET.has(commandName)) {\n const moduleName = commandToModule(commandName as Command);\n\n /* eslint-disable @typescript-eslint/no-
|
|
4
|
+
"sourcesContent": ["#!/usr/bin/env node\n\n/**\n * Entry point for the CLI.\n *\n * This is where you end up when you run:\n *\n * ```bash\n * [pnpm|yarn] skuba help\n * ```\n */\n\nimport path from 'path';\n\nimport { parseProcessArgs } from './utils/args';\nimport {\n COMMAND_DIR,\n COMMAND_SET,\n type Command,\n commandToModule,\n} from './utils/command';\nimport { isCiEnv } from './utils/env';\nimport { handleCliError } from './utils/error';\nimport { showHelp } from './utils/help';\nimport { log } from './utils/logging';\nimport { showLogoAndVersionInfo } from './utils/logo';\nimport { hasProp } from './utils/validation';\n\nconst THIRTY_MINUTES = 30 * 60 * 1000;\n\nconst skuba = async () => {\n const { commandName } = parseProcessArgs(process.argv);\n\n if (COMMAND_SET.has(commandName)) {\n const moduleName = commandToModule(commandName as Command);\n\n /* eslint-disable @typescript-eslint/no-require-imports */\n const commandModule = require(\n path.join(COMMAND_DIR, moduleName),\n ) as unknown;\n\n if (!hasProp(commandModule, moduleName)) {\n log.err(log.bold(commandName), \"couldn't run! Please submit an issue.\");\n process.exitCode = 1;\n return;\n }\n\n const run = commandModule[moduleName] as () => Promise<unknown>;\n\n if (commandModule.longRunning) {\n // This is a long-running command, so we don't want to impose a timeout.\n return run();\n }\n\n // If we're not in a CI environment, we don't need to worry about timeouts, which are primarily to prevent\n // builds running \"forever\" in CI without our knowledge.\n // Local commands may run for a long time, e.g. `skuba start` or `skuba test --watch`, which are unlikely to be used in CI.\n if (!isCiEnv() || process.env.SKUBA_NO_TIMEOUT === 'true') {\n return run();\n }\n\n const timeoutId = setTimeout(\n () => {\n log.err(\n log.bold(commandName),\n 'timed out. This may indicate a process hanging - please file an issue.',\n );\n\n // Need to force exit because promises may be hanging so node won't exit on its own.\n process.exit(1);\n },\n process.env.SKUBA_TIMEOUT_MS\n ? parseInt(process.env.SKUBA_TIMEOUT_MS, 10)\n : THIRTY_MINUTES,\n );\n\n return run().finally(() => clearTimeout(timeoutId));\n }\n\n log.err(log.bold(commandName), 'is not recognised as a command.');\n await showLogoAndVersionInfo();\n showHelp();\n\n process.exitCode = 1;\n return;\n};\n\nskuba().catch(handleCliError);\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAYA,kBAAiB;AAEjB,kBAAiC;AACjC,qBAKO;AACP,iBAAwB;AACxB,mBAA+B;AAC/B,kBAAyB;AACzB,qBAAoB;AACpB,kBAAuC;AACvC,wBAAwB;AAExB,MAAM,iBAAiB,KAAK,KAAK;AAEjC,MAAM,QAAQ,YAAY;AACxB,QAAM,EAAE,YAAY,QAAI,8BAAiB,QAAQ,IAAI;AAErD,MAAI,2BAAY,IAAI,WAAW,GAAG;AAChC,UAAM,iBAAa,gCAAgB,WAAsB;AAGzD,UAAM,gBAAgB,QACpB,YAAAA,QAAK,KAAK,4BAAa,UAAU,CACnC;AAEA,QAAI,KAAC,2BAAQ,eAAe,UAAU,GAAG;AACvC,yBAAI,IAAI,mBAAI,KAAK,WAAW,GAAG,uCAAuC;AACtE,cAAQ,WAAW;AACnB;AAAA,IACF;AAEA,UAAM,MAAM,cAAc,UAAU;AAEpC,QAAI,cAAc,aAAa;AAE7B,aAAO,IAAI;AAAA,IACb;AAKA,QAAI,KAAC,oBAAQ,KAAK,QAAQ,IAAI,qBAAqB,QAAQ;AACzD,aAAO,IAAI;AAAA,IACb;AAEA,UAAM,YAAY;AAAA,MAChB,MAAM;AACJ,2BAAI;AAAA,UACF,mBAAI,KAAK,WAAW;AAAA,UACpB;AAAA,QACF;AAGA,gBAAQ,KAAK,CAAC;AAAA,MAChB;AAAA,MACA,QAAQ,IAAI,mBACR,SAAS,QAAQ,IAAI,kBAAkB,EAAE,IACzC;AAAA,IACN;AAEA,WAAO,IAAI,EAAE,QAAQ,MAAM,aAAa,SAAS,CAAC;AAAA,EACpD;AAEA,qBAAI,IAAI,mBAAI,KAAK,WAAW,GAAG,iCAAiC;AAChE,YAAM,oCAAuB;AAC7B,4BAAS;AAET,UAAQ,WAAW;AACnB;AACF;AAEA,MAAM,EAAE,MAAM,2BAAc;",
|
|
6
6
|
"names": ["path"]
|
|
7
7
|
}
|
package/lib/utils/copy.js
CHANGED
|
@@ -71,7 +71,7 @@ const copyFiles = async (opts, currentSourceDir = opts.sourceRoot, currentDestin
|
|
|
71
71
|
const filenames = await import_fs_extra.default.promises.readdir(currentSourceDir);
|
|
72
72
|
const toDestinationPath = (filename) => import_path.default.join(
|
|
73
73
|
currentDestinationDir,
|
|
74
|
-
opts.stripUnderscorePrefix ? filename.replace(/^_\./, ".").replace(/^_package\.json/, "package.json") : filename
|
|
74
|
+
opts.stripUnderscorePrefix ? filename.replace(/^_\./, ".").replace(/^_package\.json/, "package.json").replace(/^_eslint\.config\.js/, "eslint.config.js") : filename
|
|
75
75
|
);
|
|
76
76
|
const filteredFilenames = filenames.filter(
|
|
77
77
|
(filename) => opts.include(
|
package/lib/utils/copy.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/copy.ts"],
|
|
4
|
-
"sourcesContent": ["import path from 'path';\n\nimport ejs from 'ejs';\nimport fs from 'fs-extra';\n\nimport { isErrorWithCode } from './error';\nimport { log } from './logging';\n\nexport type TextProcessor = (contents: string) => string;\n\nexport const copyFile = async (\n sourcePath: string,\n destinationPath: string,\n {\n overwrite = true,\n processors,\n }: Pick<CopyFilesOptions, 'overwrite' | 'processors'>,\n) => {\n const oldContents = await fs.promises.readFile(sourcePath, 'utf8');\n\n const newContents = processors.reduce(\n (contents, process) => process(contents),\n oldContents,\n );\n\n if (oldContents === newContents && sourcePath === destinationPath) {\n return;\n }\n\n try {\n await fs.promises.writeFile(destinationPath, newContents, {\n flag: overwrite ? 'w' : 'wx',\n });\n } catch (err) {\n if (isErrorWithCode(err, 'EEXIST')) {\n return;\n }\n\n throw err;\n }\n};\n\ninterface CopyFilesOptions {\n sourceRoot: string;\n destinationRoot: string;\n\n include: (pathname: string) => boolean;\n overwrite?: boolean;\n processors: TextProcessor[];\n stripUnderscorePrefix?: boolean;\n}\n\nexport const createEjsRenderer =\n (templateData: Record<string, unknown>): TextProcessor =>\n (contents) =>\n ejs.render(contents, templateData);\n\nexport const createStringReplacer =\n (\n replacements: Array<{\n input: RegExp;\n output: string;\n }>,\n ): TextProcessor =>\n (contents) =>\n replacements.reduce(\n (newContents, { input, output }) => newContents.replace(input, output),\n contents,\n );\n\nexport const copyFiles = async (\n opts: CopyFilesOptions,\n currentSourceDir: string = opts.sourceRoot,\n currentDestinationDir: string = opts.destinationRoot,\n) => {\n const filenames = await fs.promises.readdir(currentSourceDir);\n\n const toDestinationPath = (filename: string) =>\n path.join(\n currentDestinationDir,\n opts.stripUnderscorePrefix\n ? filename\n .replace(/^_\\./, '.')\n .replace(/^_package\\.json/, 'package.json')\n : filename,\n );\n\n const filteredFilenames = filenames.filter((filename) =>\n opts.include(\n path.relative(opts.destinationRoot, toDestinationPath(filename)),\n ),\n );\n\n await Promise.all(\n filteredFilenames.map(async (filename) => {\n const sourcePath = path.join(currentSourceDir, filename);\n const destinationPath = toDestinationPath(filename);\n\n try {\n await copyFile(sourcePath, destinationPath, opts);\n } catch (err) {\n if (isErrorWithCode(err, 'EISDIR')) {\n await fs.promises.mkdir(destinationPath, { recursive: true });\n return copyFiles(opts, sourcePath, destinationPath);\n }\n\n log.err('Failed to render', log.bold(sourcePath));\n\n throw err;\n }\n }),\n );\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,iBAAgB;AAChB,sBAAe;AAEf,mBAAgC;AAChC,qBAAoB;AAIb,MAAM,WAAW,OACtB,YACA,iBACA;AAAA,EACE,YAAY;AAAA,EACZ;AACF,MACG;AACH,QAAM,cAAc,MAAM,gBAAAA,QAAG,SAAS,SAAS,YAAY,MAAM;AAEjE,QAAM,cAAc,WAAW;AAAA,IAC7B,CAAC,UAAU,YAAY,QAAQ,QAAQ;AAAA,IACvC;AAAA,EACF;AAEA,MAAI,gBAAgB,eAAe,eAAe,iBAAiB;AACjE;AAAA,EACF;AAEA,MAAI;AACF,UAAM,gBAAAA,QAAG,SAAS,UAAU,iBAAiB,aAAa;AAAA,MACxD,MAAM,YAAY,MAAM;AAAA,IAC1B,CAAC;AAAA,EACH,SAAS,KAAK;AACZ,YAAI,8BAAgB,KAAK,QAAQ,GAAG;AAClC;AAAA,IACF;AAEA,UAAM;AAAA,EACR;AACF;AAYO,MAAM,oBACX,CAAC,iBACD,CAAC,aACC,WAAAC,QAAI,OAAO,UAAU,YAAY;AAE9B,MAAM,uBACX,CACE,iBAKF,CAAC,aACC,aAAa;AAAA,EACX,CAAC,aAAa,EAAE,OAAO,OAAO,MAAM,YAAY,QAAQ,OAAO,MAAM;AAAA,EACrE;AACF;AAEG,MAAM,YAAY,OACvB,MACA,mBAA2B,KAAK,YAChC,wBAAgC,KAAK,oBAClC;AACH,QAAM,YAAY,MAAM,gBAAAD,QAAG,SAAS,QAAQ,gBAAgB;AAE5D,QAAM,oBAAoB,CAAC,aACzB,YAAAE,QAAK;AAAA,IACH;AAAA,IACA,KAAK,wBACD,SACG,QAAQ,QAAQ,GAAG,EACnB,QAAQ,mBAAmB,cAAc,
|
|
4
|
+
"sourcesContent": ["import path from 'path';\n\nimport ejs from 'ejs';\nimport fs from 'fs-extra';\n\nimport { isErrorWithCode } from './error';\nimport { log } from './logging';\n\nexport type TextProcessor = (contents: string) => string;\n\nexport const copyFile = async (\n sourcePath: string,\n destinationPath: string,\n {\n overwrite = true,\n processors,\n }: Pick<CopyFilesOptions, 'overwrite' | 'processors'>,\n) => {\n const oldContents = await fs.promises.readFile(sourcePath, 'utf8');\n\n const newContents = processors.reduce(\n (contents, process) => process(contents),\n oldContents,\n );\n\n if (oldContents === newContents && sourcePath === destinationPath) {\n return;\n }\n\n try {\n await fs.promises.writeFile(destinationPath, newContents, {\n flag: overwrite ? 'w' : 'wx',\n });\n } catch (err) {\n if (isErrorWithCode(err, 'EEXIST')) {\n return;\n }\n\n throw err;\n }\n};\n\ninterface CopyFilesOptions {\n sourceRoot: string;\n destinationRoot: string;\n\n include: (pathname: string) => boolean;\n overwrite?: boolean;\n processors: TextProcessor[];\n stripUnderscorePrefix?: boolean;\n}\n\nexport const createEjsRenderer =\n (templateData: Record<string, unknown>): TextProcessor =>\n (contents) =>\n ejs.render(contents, templateData);\n\nexport const createStringReplacer =\n (\n replacements: Array<{\n input: RegExp;\n output: string;\n }>,\n ): TextProcessor =>\n (contents) =>\n replacements.reduce(\n (newContents, { input, output }) => newContents.replace(input, output),\n contents,\n );\n\nexport const copyFiles = async (\n opts: CopyFilesOptions,\n currentSourceDir: string = opts.sourceRoot,\n currentDestinationDir: string = opts.destinationRoot,\n) => {\n const filenames = await fs.promises.readdir(currentSourceDir);\n\n const toDestinationPath = (filename: string) =>\n path.join(\n currentDestinationDir,\n opts.stripUnderscorePrefix\n ? filename\n .replace(/^_\\./, '.')\n .replace(/^_package\\.json/, 'package.json')\n .replace(/^_eslint\\.config\\.js/, 'eslint.config.js')\n : filename,\n );\n\n const filteredFilenames = filenames.filter((filename) =>\n opts.include(\n path.relative(opts.destinationRoot, toDestinationPath(filename)),\n ),\n );\n\n await Promise.all(\n filteredFilenames.map(async (filename) => {\n const sourcePath = path.join(currentSourceDir, filename);\n const destinationPath = toDestinationPath(filename);\n\n try {\n await copyFile(sourcePath, destinationPath, opts);\n } catch (err) {\n if (isErrorWithCode(err, 'EISDIR')) {\n await fs.promises.mkdir(destinationPath, { recursive: true });\n return copyFiles(opts, sourcePath, destinationPath);\n }\n\n log.err('Failed to render', log.bold(sourcePath));\n\n throw err;\n }\n }),\n );\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,iBAAgB;AAChB,sBAAe;AAEf,mBAAgC;AAChC,qBAAoB;AAIb,MAAM,WAAW,OACtB,YACA,iBACA;AAAA,EACE,YAAY;AAAA,EACZ;AACF,MACG;AACH,QAAM,cAAc,MAAM,gBAAAA,QAAG,SAAS,SAAS,YAAY,MAAM;AAEjE,QAAM,cAAc,WAAW;AAAA,IAC7B,CAAC,UAAU,YAAY,QAAQ,QAAQ;AAAA,IACvC;AAAA,EACF;AAEA,MAAI,gBAAgB,eAAe,eAAe,iBAAiB;AACjE;AAAA,EACF;AAEA,MAAI;AACF,UAAM,gBAAAA,QAAG,SAAS,UAAU,iBAAiB,aAAa;AAAA,MACxD,MAAM,YAAY,MAAM;AAAA,IAC1B,CAAC;AAAA,EACH,SAAS,KAAK;AACZ,YAAI,8BAAgB,KAAK,QAAQ,GAAG;AAClC;AAAA,IACF;AAEA,UAAM;AAAA,EACR;AACF;AAYO,MAAM,oBACX,CAAC,iBACD,CAAC,aACC,WAAAC,QAAI,OAAO,UAAU,YAAY;AAE9B,MAAM,uBACX,CACE,iBAKF,CAAC,aACC,aAAa;AAAA,EACX,CAAC,aAAa,EAAE,OAAO,OAAO,MAAM,YAAY,QAAQ,OAAO,MAAM;AAAA,EACrE;AACF;AAEG,MAAM,YAAY,OACvB,MACA,mBAA2B,KAAK,YAChC,wBAAgC,KAAK,oBAClC;AACH,QAAM,YAAY,MAAM,gBAAAD,QAAG,SAAS,QAAQ,gBAAgB;AAE5D,QAAM,oBAAoB,CAAC,aACzB,YAAAE,QAAK;AAAA,IACH;AAAA,IACA,KAAK,wBACD,SACG,QAAQ,QAAQ,GAAG,EACnB,QAAQ,mBAAmB,cAAc,EACzC,QAAQ,wBAAwB,kBAAkB,IACrD;AAAA,EACN;AAEF,QAAM,oBAAoB,UAAU;AAAA,IAAO,CAAC,aAC1C,KAAK;AAAA,MACH,YAAAA,QAAK,SAAS,KAAK,iBAAiB,kBAAkB,QAAQ,CAAC;AAAA,IACjE;AAAA,EACF;AAEA,QAAM,QAAQ;AAAA,IACZ,kBAAkB,IAAI,OAAO,aAAa;AACxC,YAAM,aAAa,YAAAA,QAAK,KAAK,kBAAkB,QAAQ;AACvD,YAAM,kBAAkB,kBAAkB,QAAQ;AAElD,UAAI;AACF,cAAM,SAAS,YAAY,iBAAiB,IAAI;AAAA,MAClD,SAAS,KAAK;AACZ,gBAAI,8BAAgB,KAAK,QAAQ,GAAG;AAClC,gBAAM,gBAAAF,QAAG,SAAS,MAAM,iBAAiB,EAAE,WAAW,KAAK,CAAC;AAC5D,iBAAO,UAAU,MAAM,YAAY,eAAe;AAAA,QACpD;AAEA,2BAAI,IAAI,oBAAoB,mBAAI,KAAK,UAAU,CAAC;AAEhD,cAAM;AAAA,MACR;AAAA,IACF,CAAC;AAAA,EACH;AACF;",
|
|
6
6
|
"names": ["fs", "ejs", "path"]
|
|
7
7
|
}
|
package/lib/wrapper/main.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/wrapper/main.ts"],
|
|
4
|
-
"sourcesContent": ["import path from 'path';\n\nimport { runFunctionHandler } from './functionHandler';\nimport { runRequestListener } from './requestListener';\n\nexport const main = async (rawEntryPoint: string, rawPort: string) => {\n const availablePort = Number(rawPort) || undefined;\n\n // Support exported function targeting, e.g. `src/module.ts#callMeMaybe`\n const [modulePath, functionName] = path\n .join(process.cwd(), rawEntryPoint)\n .split('#', 2);\n\n // Load entry point as module\n // eslint-disable-next-line @typescript-eslint/no-
|
|
4
|
+
"sourcesContent": ["import path from 'path';\n\nimport { runFunctionHandler } from './functionHandler';\nimport { runRequestListener } from './requestListener';\n\nexport const main = async (rawEntryPoint: string, rawPort: string) => {\n const availablePort = Number(rawPort) || undefined;\n\n // Support exported function targeting, e.g. `src/module.ts#callMeMaybe`\n const [modulePath, functionName] = path\n .join(process.cwd(), rawEntryPoint)\n .split('#', 2);\n\n // Load entry point as module\n // eslint-disable-next-line @typescript-eslint/no-require-imports\n const entryPoint = require(modulePath as string) as unknown;\n\n return functionName\n ? runFunctionHandler({ availablePort, entryPoint, functionName })\n : runRequestListener({ availablePort, entryPoint });\n};\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,6BAAmC;AACnC,6BAAmC;AAE5B,MAAM,OAAO,OAAO,eAAuB,YAAoB;AACpE,QAAM,gBAAgB,OAAO,OAAO,KAAK;AAGzC,QAAM,CAAC,YAAY,YAAY,IAAI,YAAAA,QAChC,KAAK,QAAQ,IAAI,GAAG,aAAa,EACjC,MAAM,KAAK,CAAC;AAIf,QAAM,aAAa,QAAQ,UAAoB;AAE/C,SAAO,mBACH,2CAAmB,EAAE,eAAe,YAAY,aAAa,CAAC,QAC9D,2CAAmB,EAAE,eAAe,WAAW,CAAC;AACtD;",
|
|
6
6
|
"names": ["path"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/wrapper/requestListener.ts"],
|
|
4
|
-
"sourcesContent": ["import http from 'http';\n\nimport { isFunction, isIpPort, isObject } from '../utils/validation';\n\nimport { serveRequestListener, startServer } from './http';\n\n// Express compatibility\ninterface FunctionConfig extends http.RequestListener {\n port?: number;\n}\n\ninterface ObjectConfig {\n // Koa compatibility\n callback?: () => http.RequestListener;\n\n requestListener?: http.RequestListener;\n\n // Fastify compatibility\n server?: http.Server;\n\n default?: Promise<unknown>;\n port?: unknown;\n}\n\nconst isConfig = (\n data: unknown,\n): data is Promise<FunctionConfig> | Promise<ObjectConfig> =>\n isFunction(data) || isObject(data);\n\ninterface Args {\n availablePort?: number;\n entryPoint: unknown;\n}\n\n/**\n * Create an HTTP server that calls into an exported `http.RequestListener`.\n *\n * This supports Express and Koa applications out of the box.\n */\nexport const runRequestListener = async ({\n availablePort,\n entryPoint,\n}: Args): Promise<void> => {\n if (!isConfig(entryPoint)) {\n // Assume an executable script with weird exports\n return;\n }\n\n let config: FunctionConfig | ObjectConfig = await entryPoint;\n\n if (typeof config === 'object' && isConfig(config.default)) {\n // Prefer `export default` over `export =`\n config = await config.default;\n }\n\n if (Object.keys(config).length === 0) {\n // Assume an executable script with no exports\n return;\n }\n\n const port = isIpPort(config.port) ? config.port : availablePort;\n\n // http.Server support\n if (typeof config !== 'function' && config instanceof http.Server) {\n return startServer(config, port);\n }\n\n // Fastify workaround\n if (\n typeof config !== 'function' &&\n config.server &&\n config.server instanceof http.Server\n ) {\n return startServer(config.server, port);\n }\n\n const requestListener =\n typeof config === 'function'\n ? config\n : config.requestListener ?? config.callback?.();\n\n if (typeof requestListener !== 'function') {\n // Assume an executable script with non-request listener exports\n return;\n }\n\n return serveRequestListener(requestListener, port);\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,wBAA+C;AAE/C,IAAAA,eAAkD;AAoBlD,MAAM,WAAW,CACf,aAEA,8BAAW,IAAI,SAAK,4BAAS,IAAI;AAY5B,MAAM,qBAAqB,OAAO;AAAA,EACvC;AAAA,EACA;AACF,MAA2B;AACzB,MAAI,CAAC,SAAS,UAAU,GAAG;AAEzB;AAAA,EACF;AAEA,MAAI,SAAwC,MAAM;AAElD,MAAI,OAAO,WAAW,YAAY,SAAS,OAAO,OAAO,GAAG;AAE1D,aAAS,MAAM,OAAO;AAAA,EACxB;AAEA,MAAI,OAAO,KAAK,MAAM,EAAE,WAAW,GAAG;AAEpC;AAAA,EACF;AAEA,QAAM,WAAO,4BAAS,OAAO,IAAI,IAAI,OAAO,OAAO;AAGnD,MAAI,OAAO,WAAW,cAAc,kBAAkB,YAAAC,QAAK,QAAQ;AACjE,eAAO,0BAAY,QAAQ,IAAI;AAAA,EACjC;AAGA,MACE,OAAO,WAAW,cAClB,OAAO,UACP,OAAO,kBAAkB,YAAAA,QAAK,QAC9B;AACA,eAAO,0BAAY,OAAO,QAAQ,IAAI;AAAA,EACxC;AAEA,QAAM,kBACJ,OAAO,WAAW,aACd,
|
|
4
|
+
"sourcesContent": ["import http from 'http';\n\nimport { isFunction, isIpPort, isObject } from '../utils/validation';\n\nimport { serveRequestListener, startServer } from './http';\n\n// Express compatibility\ninterface FunctionConfig extends http.RequestListener {\n port?: number;\n}\n\ninterface ObjectConfig {\n // Koa compatibility\n callback?: () => http.RequestListener;\n\n requestListener?: http.RequestListener;\n\n // Fastify compatibility\n server?: http.Server;\n\n default?: Promise<unknown>;\n port?: unknown;\n}\n\nconst isConfig = (\n data: unknown,\n): data is Promise<FunctionConfig> | Promise<ObjectConfig> =>\n isFunction(data) || isObject(data);\n\ninterface Args {\n availablePort?: number;\n entryPoint: unknown;\n}\n\n/**\n * Create an HTTP server that calls into an exported `http.RequestListener`.\n *\n * This supports Express and Koa applications out of the box.\n */\nexport const runRequestListener = async ({\n availablePort,\n entryPoint,\n}: Args): Promise<void> => {\n if (!isConfig(entryPoint)) {\n // Assume an executable script with weird exports\n return;\n }\n\n let config: FunctionConfig | ObjectConfig = await entryPoint;\n\n if (typeof config === 'object' && isConfig(config.default)) {\n // Prefer `export default` over `export =`\n config = await config.default;\n }\n\n if (Object.keys(config).length === 0) {\n // Assume an executable script with no exports\n return;\n }\n\n const port = isIpPort(config.port) ? config.port : availablePort;\n\n // http.Server support\n if (typeof config !== 'function' && config instanceof http.Server) {\n return startServer(config, port);\n }\n\n // Fastify workaround\n if (\n typeof config !== 'function' &&\n config.server &&\n config.server instanceof http.Server\n ) {\n return startServer(config.server, port);\n }\n\n const requestListener =\n typeof config === 'function'\n ? config\n : (config.requestListener ?? config.callback?.());\n\n if (typeof requestListener !== 'function') {\n // Assume an executable script with non-request listener exports\n return;\n }\n\n return serveRequestListener(requestListener, port);\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,wBAA+C;AAE/C,IAAAA,eAAkD;AAoBlD,MAAM,WAAW,CACf,aAEA,8BAAW,IAAI,SAAK,4BAAS,IAAI;AAY5B,MAAM,qBAAqB,OAAO;AAAA,EACvC;AAAA,EACA;AACF,MAA2B;AACzB,MAAI,CAAC,SAAS,UAAU,GAAG;AAEzB;AAAA,EACF;AAEA,MAAI,SAAwC,MAAM;AAElD,MAAI,OAAO,WAAW,YAAY,SAAS,OAAO,OAAO,GAAG;AAE1D,aAAS,MAAM,OAAO;AAAA,EACxB;AAEA,MAAI,OAAO,KAAK,MAAM,EAAE,WAAW,GAAG;AAEpC;AAAA,EACF;AAEA,QAAM,WAAO,4BAAS,OAAO,IAAI,IAAI,OAAO,OAAO;AAGnD,MAAI,OAAO,WAAW,cAAc,kBAAkB,YAAAC,QAAK,QAAQ;AACjE,eAAO,0BAAY,QAAQ,IAAI;AAAA,EACjC;AAGA,MACE,OAAO,WAAW,cAClB,OAAO,UACP,OAAO,kBAAkB,YAAAA,QAAK,QAC9B;AACA,eAAO,0BAAY,OAAO,QAAQ,IAAI;AAAA,EACxC;AAEA,QAAM,kBACJ,OAAO,WAAW,aACd,SACC,OAAO,mBAAmB,OAAO,WAAW;AAEnD,MAAI,OAAO,oBAAoB,YAAY;AAEzC;AAAA,EACF;AAEA,aAAO,mCAAqB,iBAAiB,IAAI;AACnD;",
|
|
6
6
|
"names": ["import_http", "http"]
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skuba",
|
|
3
|
-
"version": "9.0.0-main-
|
|
3
|
+
"version": "9.0.0-main-20240928013837",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "SEEK development toolkit for backend applications and packages",
|
|
6
6
|
"homepage": "https://github.com/seek-oss/skuba#readme",
|
|
@@ -51,6 +51,7 @@
|
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
53
|
"@esbuild-plugins/tsconfig-paths": "^0.1.0",
|
|
54
|
+
"@eslint/migrate-config": "^1.2.0",
|
|
54
55
|
"@jest/types": "^29.0.0",
|
|
55
56
|
"@octokit/graphql": "^8.0.0",
|
|
56
57
|
"@octokit/graphql-schema": "^15.3.0",
|
|
@@ -59,12 +60,12 @@
|
|
|
59
60
|
"@types/jest": "^29.0.0",
|
|
60
61
|
"@types/node": "^20.16.5",
|
|
61
62
|
"chalk": "^4.1.0",
|
|
62
|
-
"concurrently": "^
|
|
63
|
+
"concurrently": "^9.0.0",
|
|
63
64
|
"dotenv": "^16.0.0",
|
|
64
65
|
"ejs": "^3.1.6",
|
|
65
66
|
"enquirer": "^2.3.6",
|
|
66
|
-
"esbuild": "~0.
|
|
67
|
-
"eslint": "^
|
|
67
|
+
"esbuild": "~0.24.0",
|
|
68
|
+
"eslint": "^9.11.1",
|
|
68
69
|
"execa": "^5.0.0",
|
|
69
70
|
"fast-glob": "^3.3.2",
|
|
70
71
|
"find-up": "^5.0.0",
|
|
@@ -80,7 +81,7 @@
|
|
|
80
81
|
"libnpmsearch": "^7.0.0",
|
|
81
82
|
"lodash.mergewith": "^4.6.2",
|
|
82
83
|
"minimist": "^1.2.6",
|
|
83
|
-
"normalize-package-data": "^
|
|
84
|
+
"normalize-package-data": "^7.0.0",
|
|
84
85
|
"npm-run-path": "^4.0.1",
|
|
85
86
|
"npm-which": "^3.0.1",
|
|
86
87
|
"picomatch": "^4.0.0",
|
|
@@ -98,9 +99,9 @@
|
|
|
98
99
|
"tsconfig-seek": "2.0.0",
|
|
99
100
|
"tsx": "^4.16.2",
|
|
100
101
|
"typescript": "~5.6.0",
|
|
101
|
-
"validate-npm-package-name": "^
|
|
102
|
+
"validate-npm-package-name": "^6.0.0",
|
|
102
103
|
"zod": "^3.22.4",
|
|
103
|
-
"eslint-config-skuba": "
|
|
104
|
+
"eslint-config-skuba": "5.0.0-main-20240928013837"
|
|
104
105
|
},
|
|
105
106
|
"devDependencies": {
|
|
106
107
|
"@changesets/cli": "2.27.8",
|
|
@@ -120,12 +121,12 @@
|
|
|
120
121
|
"@types/supertest": "6.0.2",
|
|
121
122
|
"@types/validate-npm-package-name": "4.0.2",
|
|
122
123
|
"enhanced-resolve": "5.17.1",
|
|
123
|
-
"express": "4.
|
|
124
|
-
"fastify": "
|
|
124
|
+
"express": "4.21.0",
|
|
125
|
+
"fastify": "5.0.0",
|
|
125
126
|
"jest-diff": "29.7.0",
|
|
126
127
|
"jsonfile": "6.1.0",
|
|
127
128
|
"koa": "2.15.3",
|
|
128
|
-
"memfs": "4.
|
|
129
|
+
"memfs": "4.12.0",
|
|
129
130
|
"remark-cli": "12.0.1",
|
|
130
131
|
"remark-preset-lint-recommended": "7.0.0",
|
|
131
132
|
"semver": "7.6.3",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
module.exports = require('eslint-config-skuba');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# syntax=docker/dockerfile:1.10
|
|
2
2
|
|
|
3
|
-
FROM
|
|
3
|
+
FROM public.ecr.aws/docker/library/node:20-alpine AS dev-deps
|
|
4
4
|
|
|
5
5
|
RUN --mount=type=bind,source=package.json,target=package.json \
|
|
6
6
|
corepack enable pnpm && corepack install
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"test:watch": "skuba test --watch"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@seek/logger": "^
|
|
16
|
+
"@seek/logger": "^9.0.0",
|
|
17
17
|
"express": "^4.17.1",
|
|
18
18
|
"hot-shots": "^10.0.0",
|
|
19
19
|
"seek-datadog-custom-metrics": "^4.6.3",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"skuba": "*",
|
|
29
29
|
"supertest": "^7.0.0"
|
|
30
30
|
},
|
|
31
|
-
"packageManager": "pnpm@9.
|
|
31
|
+
"packageManager": "pnpm@9.11.0",
|
|
32
32
|
"engines": {
|
|
33
33
|
"node": ">=20"
|
|
34
34
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# syntax=docker/dockerfile:1.10
|
|
2
2
|
|
|
3
|
-
FROM
|
|
3
|
+
FROM public.ecr.aws/docker/library/node:20-alpine AS dev-deps
|
|
4
4
|
|
|
5
5
|
RUN --mount=type=bind,source=package.json,target=package.json \
|
|
6
6
|
corepack enable pnpm && corepack install
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"@types/node": "^20.9.0",
|
|
20
|
-
"skuba": "9.0.0-main-
|
|
20
|
+
"skuba": "9.0.0-main-20240928013837"
|
|
21
21
|
},
|
|
22
|
-
"packageManager": "pnpm@9.
|
|
22
|
+
"packageManager": "pnpm@9.11.0",
|
|
23
23
|
"engines": {
|
|
24
24
|
"node": ">=20"
|
|
25
25
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# syntax=docker/dockerfile:1.10
|
|
2
2
|
|
|
3
|
-
FROM
|
|
3
|
+
FROM public.ecr.aws/docker/library/node:20-alpine AS dev-deps
|
|
4
4
|
|
|
5
5
|
RUN --mount=type=bind,source=package.json,target=package.json \
|
|
6
6
|
corepack enable pnpm && corepack install
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"test:watch": "skuba test --watch"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@koa/router": "^
|
|
16
|
+
"@koa/router": "^13.0.0",
|
|
17
17
|
"@opentelemetry/api": "^1.9.0",
|
|
18
18
|
"@opentelemetry/core": "^1.25.0",
|
|
19
19
|
"@opentelemetry/exporter-trace-otlp-grpc": "^0.53.0",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"@opentelemetry/instrumentation-http": "^0.53.0",
|
|
22
22
|
"@opentelemetry/propagator-b3": "^1.25.0",
|
|
23
23
|
"@opentelemetry/sdk-node": "^0.53.0",
|
|
24
|
-
"@seek/logger": "^
|
|
24
|
+
"@seek/logger": "^9.0.0",
|
|
25
25
|
"hot-shots": "^10.0.0",
|
|
26
26
|
"koa": "^2.13.4",
|
|
27
27
|
"koa-bodyparser": "^4.3.0",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"skuba": "*",
|
|
45
45
|
"supertest": "^7.0.0"
|
|
46
46
|
},
|
|
47
|
-
"packageManager": "pnpm@9.
|
|
47
|
+
"packageManager": "pnpm@9.11.0",
|
|
48
48
|
"engines": {
|
|
49
49
|
"node": ">=20"
|
|
50
50
|
}
|
|
@@ -203,7 +203,7 @@ describe('createApp', () => {
|
|
|
203
203
|
|
|
204
204
|
it('handles null error', async () => {
|
|
205
205
|
middleware.mockImplementation(() => {
|
|
206
|
-
/* eslint-disable-next-line
|
|
206
|
+
/* eslint-disable-next-line @typescript-eslint/only-throw-error */
|
|
207
207
|
throw null;
|
|
208
208
|
});
|
|
209
209
|
|
|
@@ -233,6 +233,7 @@ describe('createApp', () => {
|
|
|
233
233
|
const err = chance.sentence();
|
|
234
234
|
|
|
235
235
|
middleware.mockImplementation(() => {
|
|
236
|
+
// eslint-disable-next-line @typescript-eslint/only-throw-error
|
|
236
237
|
throw err;
|
|
237
238
|
});
|
|
238
239
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# syntax=docker/dockerfile:1.10
|
|
2
2
|
|
|
3
|
-
FROM
|
|
3
|
+
FROM public.ecr.aws/docker/library/node:20-alpine AS dev-deps
|
|
4
4
|
|
|
5
5
|
RUN --mount=type=bind,source=package.json,target=package.json \
|
|
6
6
|
corepack enable pnpm && corepack install
|
|
@@ -18,8 +18,8 @@
|
|
|
18
18
|
"@aws-sdk/client-codedeploy": "^3.363.0",
|
|
19
19
|
"@aws-sdk/client-lambda": "^3.363.0",
|
|
20
20
|
"@aws-sdk/client-sns": "^3.363.0",
|
|
21
|
-
"@seek/logger": "^
|
|
22
|
-
"datadog-lambda-js": "^
|
|
21
|
+
"@seek/logger": "^9.0.0",
|
|
22
|
+
"datadog-lambda-js": "^9.0.0",
|
|
23
23
|
"dd-trace": "^5.0.0",
|
|
24
24
|
"skuba-dive": "^2.0.0",
|
|
25
25
|
"zod": "^3.19.1"
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"serverless-prune-plugin": "^2.0.0",
|
|
39
39
|
"skuba": "*"
|
|
40
40
|
},
|
|
41
|
-
"packageManager": "pnpm@9.
|
|
41
|
+
"packageManager": "pnpm@9.11.0",
|
|
42
42
|
"engines": {
|
|
43
43
|
"node": ">=20"
|
|
44
44
|
}
|
|
@@ -304,6 +304,12 @@ exports[`returns expected CloudFormation stack for dev 1`] = `
|
|
|
304
304
|
],
|
|
305
305
|
],
|
|
306
306
|
},
|
|
307
|
+
"Tags": [
|
|
308
|
+
{
|
|
309
|
+
"Key": "aws-codedeploy-hooks",
|
|
310
|
+
"Value": "x.x.x-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
|
|
311
|
+
},
|
|
312
|
+
],
|
|
307
313
|
},
|
|
308
314
|
"Type": "AWS::Lambda::EventSourceMapping",
|
|
309
315
|
},
|
|
@@ -1007,6 +1013,12 @@ exports[`returns expected CloudFormation stack for prod 1`] = `
|
|
|
1007
1013
|
],
|
|
1008
1014
|
],
|
|
1009
1015
|
},
|
|
1016
|
+
"Tags": [
|
|
1017
|
+
{
|
|
1018
|
+
"Key": "aws-codedeploy-hooks",
|
|
1019
|
+
"Value": "x.x.x-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
|
|
1020
|
+
},
|
|
1021
|
+
],
|
|
1010
1022
|
},
|
|
1011
1023
|
"Type": "AWS::Lambda::EventSourceMapping",
|
|
1012
1024
|
},
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"@aws-sdk/client-codedeploy": "^3.363.0",
|
|
17
17
|
"@aws-sdk/client-lambda": "^3.363.0",
|
|
18
18
|
"@aws-sdk/client-sns": "^3.363.0",
|
|
19
|
-
"@seek/logger": "^
|
|
19
|
+
"@seek/logger": "^9.0.0",
|
|
20
20
|
"skuba-dive": "^2.0.0",
|
|
21
21
|
"zod": "^3.19.1"
|
|
22
22
|
},
|
|
@@ -28,9 +28,9 @@
|
|
|
28
28
|
"aws-cdk-lib": "^2.109.0",
|
|
29
29
|
"constructs": "^10.0.17",
|
|
30
30
|
"pino-pretty": "^11.0.0",
|
|
31
|
-
"skuba": "9.0.0-main-
|
|
31
|
+
"skuba": "9.0.0-main-20240928013837"
|
|
32
32
|
},
|
|
33
|
-
"packageManager": "pnpm@9.
|
|
33
|
+
"packageManager": "pnpm@9.11.0",
|
|
34
34
|
"engines": {
|
|
35
35
|
"node": ">=20"
|
|
36
36
|
}
|
|
File without changes
|