@netlify/build 29.3.0 → 29.4.88-test
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/lib/core/build.js +8 -4
- package/lib/core/config.js +2 -1
- package/lib/core/flags.js +5 -0
- package/lib/plugins_core/deploy/index.js +1 -1
- package/lib/plugins_core/functions/index.js +9 -8
- package/lib/plugins_core/save_artifacts/index.js +33 -0
- package/lib/steps/core_step.js +2 -1
- package/lib/steps/get.js +2 -1
- package/lib/steps/run_step.js +8 -4
- package/lib/steps/run_steps.js +2 -1
- package/package.json +4 -5
package/lib/core/build.js
CHANGED
|
@@ -30,7 +30,7 @@ export const startBuild = function (flags) {
|
|
|
30
30
|
const errorMonitor = startErrorMonitor({ flags: flagsA, logs, bugsnagKey });
|
|
31
31
|
return { ...flagsA, errorMonitor, logs, timers };
|
|
32
32
|
};
|
|
33
|
-
const tExecBuild = async function ({ config, defaultConfig, cachedConfig, cachedConfigPath, cwd, repositoryRoot, apiHost, token, siteId, context, branch, baseRelDir, env: envOpt, debug, systemLogFile, verbose, nodePath, functionsDistDir, edgeFunctionsDistDir, cacheDir, dry, mode, offline, deployId, buildId, testOpts, errorMonitor, errorParams, logs, timers, buildbotServerSocket, sendStatus, saveConfig, featureFlags, timeline, devCommand, quiet, }) {
|
|
33
|
+
const tExecBuild = async function ({ config, defaultConfig, cachedConfig, cachedConfigPath, outputConfigPath, cwd, repositoryRoot, apiHost, token, siteId, context, branch, baseRelDir, env: envOpt, debug, systemLogFile, verbose, nodePath, functionsDistDir, edgeFunctionsDistDir, cacheDir, dry, mode, offline, deployId, buildId, testOpts, errorMonitor, errorParams, logs, timers, buildbotServerSocket, sendStatus, saveConfig, featureFlags, timeline, devCommand, quiet, }) {
|
|
34
34
|
const configOpts = getConfigOpts({
|
|
35
35
|
config,
|
|
36
36
|
defaultConfig,
|
|
@@ -84,6 +84,7 @@ const tExecBuild = async function ({ config, defaultConfig, cachedConfig, cached
|
|
|
84
84
|
configOpts,
|
|
85
85
|
siteInfo,
|
|
86
86
|
configPath,
|
|
87
|
+
outputConfigPath,
|
|
87
88
|
headersPath,
|
|
88
89
|
redirectsPath,
|
|
89
90
|
buildDir,
|
|
@@ -127,7 +128,7 @@ const tExecBuild = async function ({ config, defaultConfig, cachedConfig, cached
|
|
|
127
128
|
};
|
|
128
129
|
export const execBuild = measureDuration(tExecBuild, 'total', { parentTag: 'build_site' });
|
|
129
130
|
// Runs a build then report any plugin statuses
|
|
130
|
-
export const runAndReportBuild = async function ({ pluginsOptions, netlifyConfig, configOpts, siteInfo, configPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, packageJson, userNodeVersion, childEnv, context, branch, buildbotServerSocket, constants, dry, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, timers, sendStatus, saveConfig, testOpts, featureFlags, timeline, devCommand, quiet, }) {
|
|
131
|
+
export const runAndReportBuild = async function ({ pluginsOptions, netlifyConfig, configOpts, siteInfo, configPath, outputConfigPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, packageJson, userNodeVersion, childEnv, context, branch, buildbotServerSocket, constants, dry, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, timers, sendStatus, saveConfig, testOpts, featureFlags, timeline, devCommand, quiet, }) {
|
|
131
132
|
try {
|
|
132
133
|
const { stepsCount, netlifyConfig: netlifyConfigA, statuses, pluginsOptions: pluginsOptionsA, failedPlugins, timers: timersA, configMutations, } = await initAndRunBuild({
|
|
133
134
|
pluginsOptions,
|
|
@@ -135,6 +136,7 @@ export const runAndReportBuild = async function ({ pluginsOptions, netlifyConfig
|
|
|
135
136
|
configOpts,
|
|
136
137
|
siteInfo,
|
|
137
138
|
configPath,
|
|
139
|
+
outputConfigPath,
|
|
138
140
|
headersPath,
|
|
139
141
|
redirectsPath,
|
|
140
142
|
buildDir,
|
|
@@ -224,7 +226,7 @@ export const runAndReportBuild = async function ({ pluginsOptions, netlifyConfig
|
|
|
224
226
|
}
|
|
225
227
|
};
|
|
226
228
|
// Initialize plugin processes then runs a build
|
|
227
|
-
const initAndRunBuild = async function ({ pluginsOptions, netlifyConfig, configOpts, siteInfo, configPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, packageJson, userNodeVersion, childEnv, context, branch, dry, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, sendStatus, saveConfig, timers, testOpts, buildbotServerSocket, constants, featureFlags, timeline, devCommand, quiet, }) {
|
|
229
|
+
const initAndRunBuild = async function ({ pluginsOptions, netlifyConfig, configOpts, siteInfo, configPath, outputConfigPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, packageJson, userNodeVersion, childEnv, context, branch, dry, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, sendStatus, saveConfig, timers, testOpts, buildbotServerSocket, constants, featureFlags, timeline, devCommand, quiet, }) {
|
|
228
230
|
const { pluginsOptions: pluginsOptionsA, timers: timersA } = await getPluginsOptions({
|
|
229
231
|
pluginsOptions,
|
|
230
232
|
netlifyConfig,
|
|
@@ -261,6 +263,7 @@ const initAndRunBuild = async function ({ pluginsOptions, netlifyConfig, configO
|
|
|
261
263
|
configOpts,
|
|
262
264
|
packageJson,
|
|
263
265
|
configPath,
|
|
266
|
+
outputConfigPath,
|
|
264
267
|
headersPath,
|
|
265
268
|
redirectsPath,
|
|
266
269
|
buildDir,
|
|
@@ -314,7 +317,7 @@ const initAndRunBuild = async function ({ pluginsOptions, netlifyConfig, configO
|
|
|
314
317
|
};
|
|
315
318
|
// Load plugin main files, retrieve their event handlers then runs them,
|
|
316
319
|
// together with the build command
|
|
317
|
-
const runBuild = async function ({ childProcesses, pluginsOptions, netlifyConfig, configOpts, packageJson, configPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, dry, buildbotServerSocket, constants, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, timeline, devCommand, quiet, }) {
|
|
320
|
+
const runBuild = async function ({ childProcesses, pluginsOptions, netlifyConfig, configOpts, packageJson, configPath, outputConfigPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, dry, buildbotServerSocket, constants, mode, api, errorMonitor, deployId, errorParams, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, timeline, devCommand, quiet, }) {
|
|
318
321
|
const { pluginsSteps, timers: timersA } = await loadPlugins({
|
|
319
322
|
pluginsOptions,
|
|
320
323
|
childProcesses,
|
|
@@ -334,6 +337,7 @@ const runBuild = async function ({ childProcesses, pluginsOptions, netlifyConfig
|
|
|
334
337
|
buildbotServerSocket,
|
|
335
338
|
events,
|
|
336
339
|
configPath,
|
|
340
|
+
outputConfigPath,
|
|
337
341
|
headersPath,
|
|
338
342
|
redirectsPath,
|
|
339
343
|
buildDir,
|
package/lib/core/config.js
CHANGED
|
@@ -97,13 +97,14 @@ export const resolveUpdatedConfig = async function (configOpts, configMutations)
|
|
|
97
97
|
// This is only done when `saveConfig` is `true`. This allows performing this
|
|
98
98
|
// in the buildbot but not in local builds, since only the latter run in a
|
|
99
99
|
// container and we want to avoid saving files on local machines.
|
|
100
|
-
export const saveUpdatedConfig = async function ({ configMutations, buildDir, repositoryRoot, configPath = `${repositoryRoot}/netlify.toml`, headersPath, redirectsPath, logs, featureFlags, context, branch, debug, saveConfig, }) {
|
|
100
|
+
export const saveUpdatedConfig = async function ({ configMutations, buildDir, repositoryRoot, configPath = `${repositoryRoot}/netlify.toml`, outputConfigPath = configPath, headersPath, redirectsPath, logs, featureFlags, context, branch, debug, saveConfig, }) {
|
|
101
101
|
if (!saveConfig) {
|
|
102
102
|
return;
|
|
103
103
|
}
|
|
104
104
|
await updateConfig(configMutations, {
|
|
105
105
|
buildDir,
|
|
106
106
|
configPath,
|
|
107
|
+
outputConfigPath,
|
|
107
108
|
headersPath,
|
|
108
109
|
redirectsPath,
|
|
109
110
|
context,
|
package/lib/core/flags.js
CHANGED
|
@@ -162,6 +162,11 @@ Default: false`,
|
|
|
162
162
|
describe: 'Whether configuration changes should be saved to netlify.toml',
|
|
163
163
|
hidden: true,
|
|
164
164
|
},
|
|
165
|
+
outputConfigPath: {
|
|
166
|
+
type: 'string',
|
|
167
|
+
describe: 'Path where to save the netlify.toml resulting from configuration changes. Only applicable if `saveConfig` is set. Defaults to "netlify.toml" in the root directory.',
|
|
168
|
+
hidden: true,
|
|
169
|
+
},
|
|
165
170
|
testOpts: {
|
|
166
171
|
describe: 'Options for testing only',
|
|
167
172
|
hidden: true,
|
|
@@ -36,7 +36,7 @@ const coreStep = async function ({ buildDir, configPath, repositoryRoot, constan
|
|
|
36
36
|
await closeBuildbotClient(client);
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
|
-
const shouldDeploy = function ({ buildbotServerSocket }) {
|
|
39
|
+
export const shouldDeploy = function ({ buildbotServerSocket }) {
|
|
40
40
|
return buildbotServerSocket !== undefined;
|
|
41
41
|
};
|
|
42
42
|
export const deploySite = {
|
|
@@ -6,9 +6,10 @@ import { logBundleResults, logFunctionsNonExistingDir, logFunctionsToBundle } fr
|
|
|
6
6
|
import { getZipError } from './error.js';
|
|
7
7
|
import { getUserAndInternalFunctions, validateFunctionsSrc } from './utils.js';
|
|
8
8
|
import { getZisiParameters } from './zisi.js';
|
|
9
|
-
//
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
// Get a list of all unique bundlers in this run
|
|
10
|
+
const getBundlers = (results = []) => Array.from(new Set(results
|
|
11
|
+
.map((bundle) => (bundle.runtime === "js" /* RuntimeType.JAVASCRIPT */ ? bundle.bundler : null))
|
|
12
|
+
.filter(Boolean)));
|
|
12
13
|
const zipFunctionsAndLogResults = async ({ buildDir, childEnv, featureFlags, functionsConfig, functionsDist, functionsSrc, internalFunctionsSrc, isRunningLocally, logs, repositoryRoot, }) => {
|
|
13
14
|
const zisiParameters = getZisiParameters({
|
|
14
15
|
buildDir,
|
|
@@ -20,14 +21,14 @@ const zipFunctionsAndLogResults = async ({ buildDir, childEnv, featureFlags, fun
|
|
|
20
21
|
isRunningLocally,
|
|
21
22
|
repositoryRoot,
|
|
22
23
|
});
|
|
23
|
-
const bundler = isUsingEsbuild(functionsConfig) ? 'esbuild' : 'zisi';
|
|
24
24
|
try {
|
|
25
25
|
// Printing an empty line before bundling output.
|
|
26
26
|
log(logs, '');
|
|
27
27
|
const sourceDirectories = [internalFunctionsSrc, functionsSrc].filter(Boolean);
|
|
28
28
|
const results = await zipItAndShipIt.zipFunctions(sourceDirectories, functionsDist, zisiParameters);
|
|
29
|
+
const bundlers = getBundlers(results);
|
|
29
30
|
logBundleResults({ logs, results });
|
|
30
|
-
return {
|
|
31
|
+
return { bundlers };
|
|
31
32
|
}
|
|
32
33
|
catch (error) {
|
|
33
34
|
throw await getZipError(error, functionsSrc);
|
|
@@ -39,7 +40,7 @@ const coreStep = async function ({ childEnv, constants: { INTERNAL_FUNCTIONS_SRC
|
|
|
39
40
|
const functionsDist = resolve(buildDir, relativeFunctionsDist);
|
|
40
41
|
const internalFunctionsSrc = resolve(buildDir, relativeInternalFunctionsSrc);
|
|
41
42
|
const internalFunctionsSrcExists = await pathExists(internalFunctionsSrc);
|
|
42
|
-
const functionsSrcExists = await validateFunctionsSrc({ functionsSrc,
|
|
43
|
+
const functionsSrcExists = await validateFunctionsSrc({ functionsSrc, relativeFunctionsSrc });
|
|
43
44
|
const [userFunctions = [], internalFunctions = []] = await getUserAndInternalFunctions({
|
|
44
45
|
featureFlags,
|
|
45
46
|
functionsSrc,
|
|
@@ -64,7 +65,7 @@ const coreStep = async function ({ childEnv, constants: { INTERNAL_FUNCTIONS_SRC
|
|
|
64
65
|
if (userFunctions.length === 0 && internalFunctions.length === 0) {
|
|
65
66
|
return {};
|
|
66
67
|
}
|
|
67
|
-
const {
|
|
68
|
+
const { bundlers } = await zipFunctionsAndLogResults({
|
|
68
69
|
buildDir,
|
|
69
70
|
childEnv,
|
|
70
71
|
featureFlags,
|
|
@@ -78,7 +79,7 @@ const coreStep = async function ({ childEnv, constants: { INTERNAL_FUNCTIONS_SRC
|
|
|
78
79
|
});
|
|
79
80
|
return {
|
|
80
81
|
tags: {
|
|
81
|
-
bundler,
|
|
82
|
+
bundler: bundlers,
|
|
82
83
|
},
|
|
83
84
|
};
|
|
84
85
|
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { saveUpdatedConfig } from '../../core/config.js';
|
|
2
|
+
import { shouldDeploy } from '../deploy/index.js';
|
|
3
|
+
const coreStep = async function ({ buildDir, configPath, outputConfigPath, repositoryRoot, logs, featureFlags, context, branch, configMutations, headersPath, redirectsPath, debug, saveConfig, }) {
|
|
4
|
+
await saveUpdatedConfig({
|
|
5
|
+
configMutations,
|
|
6
|
+
buildDir,
|
|
7
|
+
repositoryRoot,
|
|
8
|
+
configPath,
|
|
9
|
+
outputConfigPath,
|
|
10
|
+
headersPath,
|
|
11
|
+
redirectsPath,
|
|
12
|
+
logs,
|
|
13
|
+
featureFlags,
|
|
14
|
+
context,
|
|
15
|
+
branch,
|
|
16
|
+
debug,
|
|
17
|
+
saveConfig,
|
|
18
|
+
});
|
|
19
|
+
return {};
|
|
20
|
+
};
|
|
21
|
+
// This step and the deploy step must be mutually exclusive, or we end up
|
|
22
|
+
// mutating the config twice.
|
|
23
|
+
const shouldSaveArtifacts = (options) => {
|
|
24
|
+
return !shouldDeploy(options) && options.saveConfig === true;
|
|
25
|
+
};
|
|
26
|
+
export const saveArtifacts = {
|
|
27
|
+
event: 'onPostBuild',
|
|
28
|
+
coreStep,
|
|
29
|
+
coreStepId: 'save_artifacts',
|
|
30
|
+
coreStepName: 'Save deploy artifacts',
|
|
31
|
+
coreStepDescription: () => 'Save deploy artifacts',
|
|
32
|
+
condition: shouldSaveArtifacts,
|
|
33
|
+
};
|
package/lib/steps/core_step.js
CHANGED
|
@@ -2,12 +2,13 @@ import { setEnvChanges } from '../env/changes.js';
|
|
|
2
2
|
import { addErrorInfo, isBuildError } from '../error/info.js';
|
|
3
3
|
import { updateNetlifyConfig, listConfigSideFiles } from './update_config.js';
|
|
4
4
|
// Fire a core step
|
|
5
|
-
export const fireCoreStep = async function ({ coreStep, coreStepId, coreStepName, configPath, buildDir, repositoryRoot, constants, buildbotServerSocket, events, logs, nodePath, childEnv, context, branch, envChanges, errorParams, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, featureFlags, debug, systemLog, saveConfig, }) {
|
|
5
|
+
export const fireCoreStep = async function ({ coreStep, coreStepId, coreStepName, configPath, outputConfigPath, buildDir, repositoryRoot, constants, buildbotServerSocket, events, logs, nodePath, childEnv, context, branch, envChanges, errorParams, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, featureFlags, debug, systemLog, saveConfig, }) {
|
|
6
6
|
try {
|
|
7
7
|
const configSideFiles = await listConfigSideFiles([headersPath, redirectsPath]);
|
|
8
8
|
const childEnvA = setEnvChanges(envChanges, { ...childEnv });
|
|
9
9
|
const { newEnvChanges = {}, configMutations: newConfigMutations = [], tags, } = await coreStep({
|
|
10
10
|
configPath,
|
|
11
|
+
outputConfigPath,
|
|
11
12
|
buildDir,
|
|
12
13
|
repositoryRoot,
|
|
13
14
|
constants,
|
package/lib/steps/get.js
CHANGED
|
@@ -3,6 +3,7 @@ import { buildCommandCore } from '../plugins_core/build_command.js';
|
|
|
3
3
|
import { deploySite } from '../plugins_core/deploy/index.js';
|
|
4
4
|
import { bundleEdgeFunctions } from '../plugins_core/edge_functions/index.js';
|
|
5
5
|
import { bundleFunctions } from '../plugins_core/functions/index.js';
|
|
6
|
+
import { saveArtifacts } from '../plugins_core/save_artifacts/index.js';
|
|
6
7
|
// Get all build steps
|
|
7
8
|
export const getSteps = function (steps) {
|
|
8
9
|
const stepsA = addCoreSteps(steps);
|
|
@@ -27,7 +28,7 @@ export const getDevSteps = function (command, steps) {
|
|
|
27
28
|
return { steps: sortedSteps, events };
|
|
28
29
|
};
|
|
29
30
|
const addCoreSteps = function (steps) {
|
|
30
|
-
return [buildCommandCore, ...steps, bundleFunctions, bundleEdgeFunctions, deploySite];
|
|
31
|
+
return [buildCommandCore, ...steps, bundleFunctions, bundleEdgeFunctions, deploySite, saveArtifacts];
|
|
31
32
|
};
|
|
32
33
|
// Sort plugin steps by event order.
|
|
33
34
|
const sortSteps = function (steps, events) {
|
package/lib/steps/run_step.js
CHANGED
|
@@ -7,7 +7,7 @@ import { fireCoreStep } from './core_step.js';
|
|
|
7
7
|
import { firePluginStep } from './plugin.js';
|
|
8
8
|
import { getStepReturn } from './return.js';
|
|
9
9
|
// Run a step (core, build command or plugin)
|
|
10
|
-
export const runStep = async function ({ event, childProcess, packageName, coreStep, coreStepId, coreStepName, coreStepDescription, pluginPackageJson, loadedFrom, origin, condition, configPath, buildDir, repositoryRoot, nodePath, index, childEnv, context, branch, envChanges, constants, steps, buildbotServerSocket, events, mode, api, errorMonitor, deployId, errorParams, error, failedPlugins, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, quiet, }) {
|
|
10
|
+
export const runStep = async function ({ event, childProcess, packageName, coreStep, coreStepId, coreStepName, coreStepDescription, pluginPackageJson, loadedFrom, origin, condition, configPath, outputConfigPath, buildDir, repositoryRoot, nodePath, index, childEnv, context, branch, envChanges, constants, steps, buildbotServerSocket, events, mode, api, errorMonitor, deployId, errorParams, error, failedPlugins, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, quiet, }) {
|
|
11
11
|
const constantsA = await addMutableConstants({ constants, buildDir, netlifyConfig });
|
|
12
12
|
if (!(await shouldRunStep({
|
|
13
13
|
event,
|
|
@@ -19,6 +19,7 @@ export const runStep = async function ({ event, childProcess, packageName, coreS
|
|
|
19
19
|
constants: constantsA,
|
|
20
20
|
buildbotServerSocket,
|
|
21
21
|
buildDir,
|
|
22
|
+
saveConfig,
|
|
22
23
|
}))) {
|
|
23
24
|
return {};
|
|
24
25
|
}
|
|
@@ -37,6 +38,7 @@ export const runStep = async function ({ event, childProcess, packageName, coreS
|
|
|
37
38
|
coreStepId,
|
|
38
39
|
coreStepName,
|
|
39
40
|
configPath,
|
|
41
|
+
outputConfigPath,
|
|
40
42
|
buildDir,
|
|
41
43
|
repositoryRoot,
|
|
42
44
|
nodePath,
|
|
@@ -121,9 +123,10 @@ export const runStep = async function ({ event, childProcess, packageName, coreS
|
|
|
121
123
|
// or available. However, one might be created by a build plugin, in which case,
|
|
122
124
|
// those core plugins should be triggered. We use a dynamic `condition()` to
|
|
123
125
|
// model this behavior.
|
|
124
|
-
const shouldRunStep = async function ({ event, packageName, error, failedPlugins, netlifyConfig, condition, constants, buildbotServerSocket, buildDir, }) {
|
|
126
|
+
const shouldRunStep = async function ({ event, packageName, error, failedPlugins, netlifyConfig, condition, constants, buildbotServerSocket, buildDir, saveConfig, }) {
|
|
125
127
|
if (failedPlugins.includes(packageName) ||
|
|
126
|
-
(condition !== undefined &&
|
|
128
|
+
(condition !== undefined &&
|
|
129
|
+
!(await condition({ buildDir, constants, buildbotServerSocket, netlifyConfig, saveConfig })))) {
|
|
127
130
|
return false;
|
|
128
131
|
}
|
|
129
132
|
if (error !== undefined) {
|
|
@@ -139,13 +142,14 @@ const getFireStep = function (packageName, coreStepId, event) {
|
|
|
139
142
|
const parentTag = normalizeTagName(packageName);
|
|
140
143
|
return measureDuration(tFireStep, event, { parentTag, category: 'pluginEvent' });
|
|
141
144
|
};
|
|
142
|
-
const tFireStep = function ({ event, childProcess, packageName, pluginPackageJson, loadedFrom, origin, coreStep, coreStepId, coreStepName, configPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, envChanges, constants, steps, buildbotServerSocket, events, error, logs, debug, systemLog, verbose, saveConfig, errorParams, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, featureFlags, }) {
|
|
145
|
+
const tFireStep = function ({ event, childProcess, packageName, pluginPackageJson, loadedFrom, origin, coreStep, coreStepId, coreStepName, configPath, outputConfigPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, envChanges, constants, steps, buildbotServerSocket, events, error, logs, debug, systemLog, verbose, saveConfig, errorParams, configOpts, netlifyConfig, configMutations, headersPath, redirectsPath, featureFlags, }) {
|
|
143
146
|
if (coreStep !== undefined) {
|
|
144
147
|
return fireCoreStep({
|
|
145
148
|
coreStep,
|
|
146
149
|
coreStepId,
|
|
147
150
|
coreStepName,
|
|
148
151
|
configPath,
|
|
152
|
+
outputConfigPath,
|
|
149
153
|
buildDir,
|
|
150
154
|
repositoryRoot,
|
|
151
155
|
constants,
|
package/lib/steps/run_steps.js
CHANGED
|
@@ -7,7 +7,7 @@ import { runStep } from './run_step.js';
|
|
|
7
7
|
// list of `failedPlugins` (that ran `utils.build.failPlugin()`).
|
|
8
8
|
// If an error arises, runs `onError` events.
|
|
9
9
|
// Runs `onEnd` events at the end, whether an error was thrown or not.
|
|
10
|
-
export const runSteps = async function ({ steps, buildbotServerSocket, events, configPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, constants, mode, api, errorMonitor, deployId, errorParams, netlifyConfig, configOpts, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, quiet, }) {
|
|
10
|
+
export const runSteps = async function ({ steps, buildbotServerSocket, events, configPath, outputConfigPath, headersPath, redirectsPath, buildDir, repositoryRoot, nodePath, childEnv, context, branch, constants, mode, api, errorMonitor, deployId, errorParams, netlifyConfig, configOpts, logs, debug, systemLog, verbose, saveConfig, timers, testOpts, featureFlags, quiet, }) {
|
|
11
11
|
const { index: stepsCount, error: errorA, netlifyConfig: netlifyConfigC, statuses: statusesB, failedPlugins: failedPluginsA, timers: timersC, configMutations: configMutationsB, } = await pReduce(steps, async ({ index, error, failedPlugins, envChanges, netlifyConfig: netlifyConfigA, configMutations, headersPath: headersPathA, redirectsPath: redirectsPathA, statuses, timers: timersA, }, { event, childProcess, packageName, coreStep, coreStepId, coreStepName, coreStepDescription, pluginPackageJson, loadedFrom, origin, condition, }) => {
|
|
12
12
|
const { newIndex = index, newError = error, failedPlugin = [], newEnvChanges = {}, netlifyConfig: netlifyConfigB = netlifyConfigA, configMutations: configMutationsA = configMutations, headersPath: headersPathB = headersPathA, redirectsPath: redirectsPathB = redirectsPathA, newStatus, timers: timersB = timersA, } = await runStep({
|
|
13
13
|
event,
|
|
@@ -22,6 +22,7 @@ export const runSteps = async function ({ steps, buildbotServerSocket, events, c
|
|
|
22
22
|
origin,
|
|
23
23
|
condition,
|
|
24
24
|
configPath,
|
|
25
|
+
outputConfigPath,
|
|
25
26
|
buildDir,
|
|
26
27
|
repositoryRoot,
|
|
27
28
|
nodePath,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netlify/build",
|
|
3
|
-
"version": "29.
|
|
3
|
+
"version": "29.4.88-test",
|
|
4
4
|
"description": "Netlify build module",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": "./lib/core/main.js",
|
|
@@ -65,11 +65,11 @@
|
|
|
65
65
|
"dependencies": {
|
|
66
66
|
"@bugsnag/js": "^7.0.0",
|
|
67
67
|
"@netlify/cache-utils": "^5.1.0",
|
|
68
|
-
"@netlify/config": "^20.
|
|
68
|
+
"@netlify/config": "^20.3.0",
|
|
69
69
|
"@netlify/edge-bundler": "8.0.0",
|
|
70
70
|
"@netlify/functions-utils": "^5.1.1",
|
|
71
71
|
"@netlify/git-utils": "^5.1.0",
|
|
72
|
-
"@netlify/plugins-list": "^6.
|
|
72
|
+
"@netlify/plugins-list": "^6.61.0",
|
|
73
73
|
"@netlify/run-utils": "^5.1.0",
|
|
74
74
|
"@netlify/zip-it-and-ship-it": "^8.2.0",
|
|
75
75
|
"@sindresorhus/slugify": "^2.0.0",
|
|
@@ -148,6 +148,5 @@
|
|
|
148
148
|
"compilerOptions": {
|
|
149
149
|
"module": "commonjs"
|
|
150
150
|
}
|
|
151
|
-
}
|
|
152
|
-
"gitHead": "7a313d1bf93d7df494c725d3984a9e7640ae4d09"
|
|
151
|
+
}
|
|
153
152
|
}
|