Skip to content

llmx-tech/n8n-cloud-deploy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš€ Deploy n8n to Google Cloud in 5 Minutes

Production-ready n8n with automatic HTTPS. No Docker knowledge required.

License: MIT Platform: GCP n8n Shell Script

Automated deployment tool for running self-hosted n8n on Google Cloud Platform with Caddy reverse proxy, automatic HTTPS via Let's Encrypt, and interactive setup.

Currently supports: Google Cloud Platform (GCP) Coming soon: AWS, Azure, DigitalOcean, and more! See Roadmap


⚑ Quick Start

Deploy n8n with one command:

curl -fsSL https://raw.githubusercontent.com/llmx-de/n8n-cloud-deploy/main/install.sh | bash

That's it! The script will:

  1. βœ… Download all necessary files
  2. βœ… Guide you through interactive setup
  3. βœ… Deploy n8n with automatic HTTPS
  4. βœ… Verify DNS propagation
  5. βœ… Give you a working n8n instance at https://your-domain.com

Time to deploy: ~5 minutes Estimated cost: $25-35/month (customizable)


✨ Why Use This Tool?

Feature What You Get
πŸ”’ Automatic HTTPS Let's Encrypt SSL certificates, auto-renewal every 60 days
🎯 Interactive Setup No config files to edit - just answer simple questions
πŸ’° Cost Transparency Choose from 7 VM sizes with upfront pricing ($8-$185/month)
πŸ›‘οΈ Production Ready Caddy reverse proxy, proper firewall rules, persistent volumes
πŸ”„ DNS Verification Auto-checks DNS propagation before proceeding
🧹 Selective Cleanup Choose what to keep (keep IP, delete instance, etc.)
πŸ“Š Resource Detection Smart detection of existing resources to prevent duplicates

πŸ“¦ What Gets Deployed?

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚   Your Domain (https://n8n.example.com) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
         β”Œβ”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
         β”‚  Caddy Proxy   β”‚  ← Automatic HTTPS
         β”‚  (Port 80/443) β”‚     Let's Encrypt
         β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                 β”‚
         β”Œβ”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
         β”‚   n8n Server   β”‚  ← Workflow Automation
         β”‚  (Port 5678)   β”‚
         β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

GCP Resources:
  β€’ Compute Engine VM (Ubuntu 22.04)
  β€’ Static IP Address
  β€’ Firewall Rules (80, 443, 22)
  β€’ Persistent Volumes (Docker)

πŸ’΅ Pricing

Choose your instance size during setup:

Machine Type vCPUs Memory Monthly Cost* Best For
e2-micro 0.25 1 GB $8-10 Testing only
e2-small 0.5 2 GB $14-16 Light usage, few workflows
e2-medium ⭐ 1 4 GB $25-35 Recommended for most users
e2-standard-2 2 8 GB $50-65 Heavy usage, many workflows
e2-standard-4 4 16 GB $97-120 Very heavy usage
n2-standard-2 2 8 GB $73-90 Better performance than e2
n2-standard-4 4 16 GB $147-185 High performance needs

*Prices include VM + Static IP + Storage. Actual costs vary by region.

πŸ’‘ Tip: You can upgrade/downgrade anytime by redeploying!

vs. n8n Cloud Pricing

Feature This Tool (Self-Hosted) n8n Cloud
Cost $25-35/month Starts at $20/month (limited)
Workflows Unlimited Limited by plan
Executions Unlimited Limited by plan
Data Control 100% yours Hosted by n8n
Customization Full access Limited

πŸ“‹ Prerequisites

Before starting, you need:

  • βœ… Google Cloud SDK (install here)
  • βœ… GCP Account with billing enabled
  • βœ… Domain Name you can manage (for DNS A record)
  • βœ… 5 minutes of your time

Permissions needed: Compute Admin, Service Account User


🎯 How It Works

Step 1: Install & Run

curl -fsSL https://raw.githubusercontent.com/llmx-de/n8n-cloud-deploy/main/install.sh | bash

Step 2: Answer Questions

The script guides you through:

  • Select your GCP project
  • Pick a region (auto-detected list)
  • Choose VM size (with pricing)
  • Enter your domain name

Step 3: Update DNS

Script shows your static IP β†’ Update your DNS A record β†’ Press Enter

Step 4: Done! πŸŽ‰

Access your n8n instance at https://your-domain.com


πŸ”§ Advanced Usage

Manual Installation

# Clone repository
git clone https://github.com/llmx-de/n8n-cloud-deploy.git
cd n8n-cloud-deploy

# Run deployment
bash provision-cloud.sh

Cleanup Options

# Interactive cleanup - choose what to delete
bash cleanup.sh

# Options:
# βœ“ Delete instance, keep IP (reuse later)
# βœ“ Delete everything (stop all charges)
# βœ“ Keep firewall for faster redeployment

SSH Access

gcloud compute ssh n8n-instance --zone=<your-zone>

Update n8n

cd /opt/n8n
sg docker -c "docker compose pull n8n"
sg docker -c "docker compose up -d --force-recreate n8n"

πŸ›‘οΈ Security

  • πŸ”’ HTTPS by default via Let's Encrypt
  • πŸ”‘ SSH access (restrict to your IP - see SECURITY.md)
  • πŸ” Firewall rules for ports 22, 80, 443
  • πŸ“ Security guide with best practices

⚠️ After deployment: Restrict SSH access to your IP! See SECURITY.md for details.


πŸ“š Documentation


πŸ—ΊοΈ Roadmap

We're actively working on expanding this tool to support more cloud providers and features!

Planned Cloud Providers

  • ☁️ AWS - Amazon Web Services support (coming soon!)
  • πŸ”· Azure - Microsoft Azure support
  • 🌊 DigitalOcean - Simple cloud deployment
  • πŸš€ Linode/Akamai - Alternative cloud hosting
  • 🌐 Hetzner - European cloud provider

Upcoming Features

  • πŸ“Š Monitoring & Alerts - Built-in monitoring setup
  • πŸ’Ύ Automated Backups - Scheduled backup configurations
  • 🐘 PostgreSQL Support - Database backend option
  • πŸ”„ Queue Mode - n8n queue mode for scaling
  • πŸ—οΈ Terraform Option - Infrastructure as Code alternative

Want to help? Check out CONTRIBUTING.md to get started!


❓ FAQ

How much does this cost per month?

Default setup (e2-medium): $25-35/month

This includes:

  • VM instance: ~$24-30
  • Static IP: $0 (when attached to running instance)
  • Storage: ~$0.40
  • Network: First 1GB free

You can choose smaller instances (from $8/month) or larger ones (up to $185/month).

Can I upgrade/downgrade the VM later?

Yes! Just delete the instance (keep the static IP) and redeploy with a different machine type. Your DNS won't need updating.

How do SSL certificates renew?

Automatically! Caddy handles Let's Encrypt certificate renewal ~30 days before expiry. No manual action needed.

What if I want to stop paying but keep my setup?

Delete the instance but keep the static IP using the cleanup script. You'll pay only ~$7/month for the IP. Redeploy anytime!

How do I backup my data?
cd /opt/n8n
sg docker -c "docker compose stop n8n"
sudo tar -czvf backup.tar.gz /var/lib/docker/volumes/n8n-cloud-deploy_n8n_data/_data
sg docker -c "docker compose start n8n"

See INSTALL.md for full backup/restore guide.

Can I use this in production?

Yes! This creates a production-ready setup with:

  • Automatic HTTPS
  • Reverse proxy (Caddy)
  • Persistent volumes
  • Proper firewall rules
  • Auto-renewing SSL certificates

Just make sure to follow security best practices in SECURITY.md.


🀝 Contributing

Contributions are welcome! Please see CONTRIBUTING.md for details.

Quick Contribution Guide

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.


πŸ™ Acknowledgments


πŸ“§ Support


Made with ❀️ for the n8n community

⭐ Star this repo if you found it helpful!

About

Automated deployment tool for running self-hosted n8n on Google Cloud Platform with Caddy reverse proxy, automatic HTTPS via Let's Encrypt, and interactive setup.

Topics

Resources

Contributing

Security policy

Stars

4 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages