Use this essential n8n workflow to automatically check for new n8n versions using a schedule n8n trigger, compare against the local install, and securely trigger updates via a Portainer webhook.
Download this n8n workflow template and start using it instantly.
DevOps specialists and system administrators managing self-hosted infrastructure.
Users running n8n via Docker/Portainer who require automated maintenance.
Maintaining a self-hosted n8n instance requires keeping it up-to-date to benefit from new features and security patches. This sophisticated n8n workflow eliminates the need for manual version checks and deployment procedures. By utilizing a scheduled n8n trigger, the system periodically checks the official npm registry for the latest n8n version, compares it against the locally installed version (extracted via the local metrics endpoint), and if a discrepancy is found, it automatically executes a deployment webhook (such as a Portainer stack webhook).
This robust n8n automation ensures your instance is always running the newest software, simplifying your maintenance routine and providing a high-value example of advanced n8n node usage in a production environment.
This powerful n8n workflow operates on a recurring schedule to enforce automatic updates:
/metrics endpoint (assuming the n8n instance is accessible locally, e.g., via 127.0.0.1) to pull current system information.To deploy this comprehensive n8n workflow, follow these steps:
https://127.0.0.1/metrics). If your instance uses self-signed certificates, ensure 'Allow Unauthorized Certificates' is enabled.https://portainer.tld.com/...) with the actual Portainer stack webhook URL you configured for your n8n deployment. This webhook is the key n8n trigger for the deployment action. Schedule Trigger: Serves as the primary n8n trigger. It is configured to initiate the workflow every 16 hours at minute 8, ensuring regular checks without overloading the system.
Get the latest n8n version (HTTP Request n8n node): Fetches version data from https://registry.npmjs.org/n8n/latest. This provides the benchmark for the required version update.
Get local n8n metrics (HTTP Request n8n node): Accesses the local n8n metrics endpoint (/metrics) to retrieve the currently running version.
local n8n version (Code n8n node): Crucial for data manipulation. This n8n node uses a JavaScript snippet and regex (/n8nversioninfo{[^}]version="(v[\d.]+)"/) to parse the complex metrics output and extract a clean, usable installed n8n version number (versionCli).
If (n8n node): Performs the version control logic. It checks if the latest version from npm is not equal to the versionCli extracted locally. Only if this condition is met does the n8n workflow proceed.
Use this powerful n8n workflow to instantly analyze uploaded PDF invoices via Telegram using OpenAI's capabilities. Automate data extraction and receive structured results.

Automate iOS configuration syncing from .env files to native Xcode settings using this powerful n8n workflow. Triggers on GitHub push, creates PRs, and sends Gmail alerts.

Use this powerful n8n workflow to automatically fetch the latest funding round data from the Crunchbase API, parse and clean the records, and sync real-time insights to both Google Sheets and Airtable daily. Essential n8n templates for market research.

Use this powerful n8n workflow to automatically invite new users to your n8n instance based on an external list in Google Sheets. Compare existing users and automate onboarding.

Use this powerful n8n workflow to instantly generate professional documentation, SEO titles, and standardized sticky notes for any n8n workflow JSON uploaded via Telegram, leveraging Google Gemini AI.

Use this powerful n8n workflow to automate a weekly Hollywood film industry briefing. It leverages Tavily search, Google Gemini AI summarization, and a Gmail n8n node for seamless delivery directly to your inbox.








































