diff --git a/docs/usage/self-hosted-experimental.md b/docs/usage/self-hosted-experimental.md index fa703514e8393d7780bf57700549595ebdee4334..ba71bd0f1a0cc6d4993e1543e5fa8c723c287553 100644 --- a/docs/usage/self-hosted-experimental.md +++ b/docs/usage/self-hosted-experimental.md @@ -40,6 +40,10 @@ If set to any string, Renovate will use this as the `user-agent` it sends with H If set to any value, Renovate will use a "hard" `process.exit()` once all work is done, even if a sub-process is otherwise delaying Node.js from exiting. See <https://github.com/renovatebot/renovate/issues/8660> for background on why this was created. +## RENOVATE_X_IGNORE_NODE_WARN + +Suppress the default warning when a deprecated version of Node.js is used to run Renovate. + ## `RENOVATE_X_PLATFORM_VERSION` If set, Renovate will use this string as GitLab server version instead of checking via the GitLab API. diff --git a/lib/workers/global/index.ts b/lib/workers/global/index.ts index d601e357c3d3fa486262259fbc54e847c59f1bcc..52e7beb5ea9a67cbcbfb58017c77f678bd541f71 100644 --- a/lib/workers/global/index.ts +++ b/lib/workers/global/index.ts @@ -63,7 +63,7 @@ function checkEnv(): void { const range = pkg.engines!.node!; const rangeNext = pkg['engines-next']?.node; if (process.release?.name !== 'node' || !process.versions?.node) { - logger.warn( + logger[process.env.RENOVATE_X_IGNORE_NODE_WARN ? 'info' : 'warn']( { release: process.release, versions: process.versions }, 'Unknown node environment detected.' ); @@ -76,7 +76,7 @@ function checkEnv(): void { rangeNext && !semver.satisfies(process.versions?.node, rangeNext) ) { - logger.warn( + logger[process.env.RENOVATE_X_IGNORE_NODE_WARN ? 'info' : 'warn']( { versions: process.versions }, `Please upgrade the version of Node.js used to run Renovate to satisfy "${rangeNext}". Support for your current version will be removed in Renovate's next major release.` ); diff --git a/package.json b/package.json index 6b7c0bf3ac5c8b463b8c2e8e4dac675cd5c7963c..d04fac80795361bb207e060d5c161bd82af4e7e9 100644 --- a/package.json +++ b/package.json @@ -132,7 +132,7 @@ }, "engines-next": { "description": "Versions other than the below are deprecated and a warning will be logged", - "node": "^16.13.0 || >= 18.12.0" + "node": ">= 18.12.0" }, "dependencies": { "@aws-sdk/client-codecommit": "3.256.0",