Skip to content

Complete ansible playbook to provision and deploy nodemation to a Digital Ocean droplet.

License

Notifications You must be signed in to change notification settings

matospadilla/n8n-ansible-install

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DigitalOcean Referral Badge

Nodemation on DigitalOcean with Ansible

Complete ansible playbook to provision and deploy nodemation to a Digital Ocean droplet.

One Click Install.

If you would prefer to NOT install n8n with ansible, and simply use Digital Ocean's App Platform, you can use this button to deploy this app template to the Digital Ocean App Platform. Doing this is slightly more expensive because you have to pay for the app & the database monthly. Whereas if you use ansible & this playbook you can install the app and the database into the same droplet and that costs less each month. But for those of you who don't want to deal with getting into the command line... it's a nice alternative.

Deploy to DO

Intro

This project created to be a one step playbook to deploy new nodemation instances to DigitalOcean using Ansible.

I wanted to:

  • Provision the droplet with a configurable admin user
  • Install the required supporting software: NodeJS, N8N, Nginx, & PM2
  • Manage fetching an SSL Certificate from Lets Encrypt
  • Configure Nginx to pass the n8n application to the https://

How to setup the project

You need Ansible to start with this project. So go get it! I used ansible 2.9.10 for the project.

  • Clone this repo into a folder on your computer:

git clone https://github.com/johnkraczek/n8n-ansible-install.git

  • Edit defaults/vars.yml with your values, Specifically update:

    • system_user:
    • email:
    • domain:
    • N8N_BASIC_AUTH_USER:
    • N8N_BASIC_AUTH_PASSWORD:
  • Edit hosts and insert the IP address of your newly minted Digital Ocean Droplet (Ubuntu 20.04.3 LTS x64)

    • Don't have a Digital Ocean Acccount yet? Get One Here use my link to get $100 off for the first 60 days.
  • Point the domain you added to default/vars.yml to the IP address you added to the hosts file. [Cloudflare DNS] (https://dash.cloudflare.com/) Note: you will need to have cloudflare NOT proxy the domain (Orange Cloud => Grey Cloud).

Install the galaxy roles:

Run ansible-galaxy install -r requirements.yml to install the galaxy roles used by the playbook.

Provision the server:

ansible-playbook main.yml

to install all of dependancies & deploy the project on the server

Additional Commands

Run this command to renew the certificate manually. The certificate renewal has been setup on a cronjob to run once every 2 months, The certificate expires every 3 months, giving you a month to fix certificate renewal issues if found.

ansible-playbook main.yml --tags=certificate

About

Complete ansible playbook to provision and deploy nodemation to a Digital Ocean droplet.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jinja 100.0%