Hey @Georgy!
To get started quickly you can sign-up on n8n.cloud where you get a free one-month trial period! However, if you’re still interested in deploying and trying it out here are the steps you can follow (these are the steps for hosting n8n on DigitalOcean. The initial steps might defer based on the cloud provider you use):
- Once you create an account on DigitalOcean, create a droplet. If you’re using AWS create an EC2 instance, on GCP this would be a VM.
- Use Ubuntu 20.04 (I prefer Ubuntu. It works well with the commands mentioned in the documentation) with 1 GB RAM (the more memory, the better performance!)
- Once your droplet is created, the next step is to configure your DNS. For GCP there are additional steps to configure the Public IP Address. With DigitalOcean, once you’re droplet is created you can copy the displayed IP address.
- Go to your Domain provider and set the A record. You can find a DNS setting option. Enter the subdomain (you can use n8n) in the Name field and the IP address in the Value field.
Note: It might take 24 to 48 hours for this configuration to take place. - Access your server (droplet). You need access to the server to install and update packages that we will use to host n8n.
- Run the commands mentioned here: Server Setup | Docs. Since we are running Ubuntu 20.04 make sure you run the relevant command.
These commands update the packages on our server and fetch and install docker. - The next step is to install docker-compose. Use the commands mentioned here: Server Setup | Docs
- We already have configured our DNS in Step 4. So the next would be to create a docker-compose file. Use the command
vi docker-compose.yml
. This will create an empty docker-compose file. - Paste the content from here: Server Setup | Docs.
- To save and exit vim (the text editor), press ESC. Then enter
:wq
You don’t have to change anything in the above file. You can use it as it is! - In the above file we are setting some variables. In this step, we will configure these variables. Run the command
vi .env
.
# Folder where data should be saved [CHANGING THIS IS NOT NECESSARY]
DATA_FOLDER=/root/n8n/
# The top-level domain to serve from [CHANGE THIS TO YOUR DOMAIN]
DOMAIN_NAME=example.com
# The subdomain to serve from [YOU CAN USE N8N AS SUBDOMAIN OR SOMETHING ELSE]
SUBDOMAIN=n8n
# DOMAIN_NAME and SUBDOMAIN combined decide where n8n will be reachable from
# above example would result in: https://n8n.example.com
# The user name to use for authentication - IMPORTANT ALWAYS CHANGE! [THIS WILL BE THE USERNAME YOU WILL USE TO SIGN-IN]
N8N_BASIC_AUTH_USER=user
# The password to use for authentication - IMPORTANT ALWAYS CHANGE! [THIS WILL BE THE PASSWORD YOU WILL USE TO SIGN-IN]
N8N_BASIC_AUTH_PASSWORD=password
# Optional timezone to set which gets used by Cron-Node by default
# If not set New York time will be used [GOOD TO CHANGE IF YOU'RE GOING TO USE CRON NODE]
GENERIC_TIMEZONE=Europe/Berlin
# The email address to use for the SSL certificate creation [YOUR EMAIL ADDRESS]
[email protected]
- Once the file is created, the next step is to create the folder that we specified for
DATA_FOLDER
. Use the following command:
mkdir /root/n8n/
NOTE: The value has to be the same as you set for DATA_FOLDER
.
13. Start docker using the command sudo docker-compose up -d
You can now navigate to [SUBDOMAIN].[DOMAIN] (eg. n8n.example.com) and use the username and password to access it!
Feel free to let me know if you get stuck at any step. I hope this helps.
P.S The video is completed and will be out soon!