Self-Hosting n8n with Docker – Step-by-Step Tutorial (NO CODE!!)
- URL: https://www.youtube.com/watch?v=dC2Q_cyzgjg
- Channel: Zubair Trabzada | AI Workshop
- Fetched: 2026-08-17T12:49:55+00:00
- Language: English (auto-generated)
Transcript
[00:00] in this tutorial I’m going to show you a
[00:01] very easy way to self-host n ATN on your
[00:04] local machine using the docker desktop
[00:06] app if you’re not familiar with Docker
[00:08] don’t worry I’ll explain everything step
[00:10] by step this is going to be completely
[00:12] no quote solution meaning that we’re
[00:14] going to utilize the docker desktop from
[00:16] start to finish all right let’s get
[00:17] started if you watched my previous video
[00:19] I showed how to uh self-host nnn via npm
[00:24] or note package manager uh through the
[00:26] terminal so in this one I’m going to
[00:28] focus solely on Docker and the desktop
[00:30] application so that way if you don’t
[00:32] know how to code or if you’re not
[00:33] familiar with the terminal this would be
[00:34] a really good way for you to host
[00:36] self-host nnn onto your local computer
[00:39] using Docker self-hosting has a lot of
[00:41] advantages first the fact that you will
[00:43] have complete control over your data so
[00:45] if you’re worried about U privacy issues
[00:47] or if you’re worried about leaking your
[00:49] data to third party app and you don’t
[00:51] want to use the cloud account so
[00:53] self-hosting will be a great option for
[00:54] you um so Docker is actually the
[00:57] preferred method U by the nnn community
[01:00] and a lot of other folks because it
[01:01] gives you a lot of advantages and
[01:03] control over how you can run and
[01:05] self-host it along with other
[01:07] applications within next videos I’ll
[01:09] show how to do that as well but anyways
[01:12] so let me quickly explain what Docker is
[01:14] for those of you who are not familiar
[01:15] with it if you’re already familiar with
[01:16] it please feel free to descript this but
[01:18] I just want to quickly introduce what
[01:19] Docker is and why this is so beneficial
[01:21] when it comes to self-hosting n ATN so
[01:23] essentially Docker is just a platform
[01:26] and it’s extremely popular uh platform
[01:28] in the developer community community
[01:30] that allows you to package application
[01:33] and all of their dependen dependencies
[01:36] into one standardized units which they
[01:38] refer to as containers so you could
[01:40] think of it as a tool that packages all
[01:43] of your application like nnn and all of
[01:46] its dependencies whatever it needs all
[01:49] into one single unit called the
[01:52] containers again NN and all other
[01:54] applications have a lot of dependency
[01:55] that it comes with such as libraries uh
[01:58] system tools and settings so what Docker
[02:01] allows for you is to put all of that in
[02:03] one container or in one unit and then
[02:06] you can basically depl deploy this um
[02:09] and run it consistently across other
[02:11] platforms so that way if you want to
[02:13] self-host yourself in a cloud account
[02:16] and a cloud provider then you can do
[02:18] that and it will behave exactly just
[02:20] like it would be in your locer machine
[02:21] so when it comes to nnn and self-hosting
[02:23] the reason why darkware is so beneficial
[02:25] is because it really simplifies the
[02:27] process of getting N1 up and running and
[02:30] because it bundles all of the necessary
[02:32] components into one package so that way
[02:34] you don’t need to manually configure
[02:36] anything or worry about any kind of
[02:38] issues or environments uh that you might
[02:40] run into so that’s what has a huge
[02:42] Advantage when it comes to the
[02:43] Simplicity in the process of running
[02:46] idence on your local computer and then
[02:48] another big Advantage is the portability
[02:50] meaning that um when you deploy Docker
[02:54] in other environments so let’s say if
[02:56] you want to um deploy it on a another
[02:58] hosting platform um what this will do is
[03:01] will make sure that it consistently
[03:03] behaves the way it will behave in your
[03:05] local computer and then another thing is
[03:07] the isolation of each container meaning
[03:09] that these containers run independently
[03:12] of each other uh meaning that if uh if
[03:14] you have several operations or several
[03:17] application NN would operate in its own
[03:20] isolated environments and again this uh
[03:23] removes any conflicts or with other
[03:25] applications that might be running so
[03:26] that’s what gives it a huge Advantage
[03:28] ensuring it’s really stable and reliable
[03:30] and another big Advantage is the SC
[03:32] scalability so as you scale your
[03:34] operations in nadn a Docker really will
[03:37] allow you to uh scale and deploy
[03:40] multiple containers based on what your
[03:42] needs are right so this really makes it
[03:45] simple to handle increased workloads and
[03:47] if you’re creating complex uh workflows
[03:50] and automation this really allows you to
[03:53] be able to scale as you go without the
[03:55] need to configure or manually change any
[03:58] of the settings so so that was kind of
[04:00] the overall gist of what uh Docker is
[04:03] and how that helps you when it comes to
[04:05] self-hosting NN so let’s go ahead and
[04:07] get started um and install Docker
[04:09] application the desktop application on
[04:11] our computer and then we’ll go ahead and
[04:13] run NN through the docker application so
[04:16] the first thing you need to do is you
[04:17] need to go over to
[04:19] doer. and you need to download it for
[04:22] your machine so um whatever you’re using
[04:24] whether you using Windows Linux or Mac
[04:27] make sure you’re downloading the correct
[04:29] version one important thing if you’re
[04:30] using Mac make sure you’re the newer
[04:32] ones especially the uh M1 M2 M3 chips
[04:36] make sure you’re downloading this
[04:37] version and not the Intel chip because
[04:40] this is not going to work otherwise so
[04:41] I’m going to go ahead and double click
[04:43] on this it’s going to download my
[04:44] application so once you do that you’re
[04:46] going to go to your downloads and then
[04:48] double click on doer. DMG and once you
[04:51] do that it’s going to ask you a few
[04:53] questions to install and once you
[04:55] install that then you can go over to
[04:57] your applications and then uh initiate
[04:59] Docker I’ve already done that so I’m
[05:01] going to go ahead and open the docker
[05:03] desktop application all right so once
[05:05] you do that this is what it’s going to
[05:06] look like so this is their uh desktop
[05:08] application it has a really nice user
[05:10] interface let me get rid of that all
[05:12] right let me maximize this so that way
[05:14] you can see this really well all right
[05:18] perfect so this is what the initial it
[05:21] might give you some uh tour but go ahead
[05:24] and skip that but you will have
[05:26] containers images volumes builds we’re
[05:29] going to focus on images and containers
[05:31] actually before we do that let’s go
[05:32] ahead and create a folder so that way we
[05:34] can put all of our nend data into that
[05:36] folder so that way uh we can keep track
[05:39] of the data that we use all right so I’m
[05:41] going to go to my finder so go to your
[05:44] homepage and right click new folder and
[05:48] then we’re going to call this nn-
[05:50] dat all right so right now the folder is
[05:53] empty all right we’re good to go here
[05:55] okay so let’s minimize this so now I’m
[05:58] going to come to my images
[06:00] and we’re going to go ahead and click on
[06:02] search images to run so here what we’re
[06:04] going to do is search for NN io/ NN I’ve
[06:08] already done that but let’s go ahead and
[06:09] do it we’re going to type n8n
[06:12] io/
[06:13] n8n okay and the first one as you can
[06:16] see right here it says 100 million plus
[06:19] 293 Stars so make sure that you’re
[06:22] downloading this image because otherwise
[06:24] it’s going to give you not downloading
[06:25] sorry you got to pull this um so make
[06:28] sure that you’re on the correct one and
[06:29] I’m going to click on
[06:31] pull and once you click on pull now as
[06:34] you can see it’s loading so now this is
[06:37] going to pull all of that data um into
[06:39] your local desktop app and it will be
[06:42] saved under the images tab and again
[06:44] we’ll take a look at that in a little
[06:45] bit so now that you have the correct
[06:47] image download here so now you can see
[06:49] here it says the size and now on the
[06:51] right hand side here it says run so for
[06:53] the first time when you click on run we
[06:55] need to set a few optional settings so
[06:57] once you click on run it’s going to open
[06:59] up this this popup where it says run a
[07:00] new container optional settings you’re
[07:02] going to click on the right hand side
[07:04] here you’re going to put a container
[07:05] name cuz otherwise it will select a
[07:08] random name so I’m just going to say n8n
[07:11] container Das container so that way I
[07:14] can recognize it all right so the host
[07:15] Port so this is where uh you want to
[07:18] host on your local computer what port
[07:20] which in a little bit I’ll show you what
[07:22] that means but for now just put
[07:25] 5678 and this will map uh this Docker
[07:29] container to to your local Port so that
[07:30] way you can access it through your um
[07:33] local machine and again like I said in a
[07:35] little bit I’ll show you how to do that
[07:37] all right so the volume this is where
[07:38] you want n it and to um store its data
[07:42] so that way if uh the container stopped
[07:46] or even it’s deleted then all of your
[07:48] data will persist so this one you’re
[07:49] going to click on this uh three dots
[07:52] here and you’re going to go ahead and
[07:53] select um the folder that you created
[07:56] right so earlier we went to our homepage
[07:58] and created this folder called in- data
[08:00] so you’re just going to double click
[08:01] select that and click on open so for the
[08:03] container pad you need to enter
[08:06] slome
[08:08] slash node and then
[08:11] slash.
[08:13] n8n and then so what this does is this
[08:16] ensures that uh the data the data on
[08:19] your host machine is synced to and itn’s
[08:24] directory inside the container of this
[08:26] Docker container so this basically
[08:28] ensures that all of the data is saved in
[08:31] the right in the correct area okay
[08:32] that’s good environment variable this is
[08:34] optional so if you want to do any kind
[08:36] of authentication this is where you will
[08:37] enter so if you want to do that you can
[08:38] go ahead and like you know use J GPT to
[08:41] put uh variables here but I’m going to
[08:43] just leave it as it is so now that we’re
[08:45] done with that all I have to do is click
[08:47] on run and as soon as I do that you can
[08:50] see now with bring s to The Container
[08:53] Tab and it runs all this stuff and then
[08:55] on the bottom as you can see now it says
[08:56] editor is now accessible via Local Host
[08:59] post 5678 and this is exactly what we
[09:02] typed earlier like the port so the 5678
[09:05] which means that now on the port in your
[09:07] local machine the port 5678 you’ll be
[09:10] able to have access to n8n so I’m just
[09:13] going to copy this and go to a new
[09:15] tab come here on top and paste
[09:19] it and there you go so now you can uh
[09:22] set up your email account so as soon as
[09:24] you uh paste that in your local machine
[09:27] you’ll it will it will take you to the
[09:29] form where now you would have to set up
[09:31] a new username and password and again
[09:33] this has nothing to do with your uh
[09:36] cloud account so therefore there is no
[09:37] migration here so go ahead and enter
[09:39] your information I’m going to go ahead
[09:41] and enter mine okay so once you do that
[09:43] click on
[09:45] next and now you have to just customize
[09:47] the NN it’ll just ask you a few question
[09:49] go through it software the
[09:51] service you I’m just going to
[09:55] say oh whatever it doesn’t really matter
[09:58] myself
[10:00] that’s
[10:01] fine Google get
[10:04] started all right so now it presents you
[10:08] the blank workflows and again it’s the
[10:10] same environment or the same user
[10:12] interface just like if you were to
[10:13] access from your cloud account you have
[10:15] your templates over here you have your
[10:17] accounts uh you have NN your credentials
[10:20] and start from scratch means that now
[10:22] you can just jump into your workflow and
[10:24] again same thing you have ability to
[10:26] access everything from your Local Host
[10:28] here um your Advanced AIS AI agents
[10:31] whatever you need all of this will be
[10:33] accessed uh one thing is if you want to
[10:35] import your workflows from your cloud
[10:38] account go to your cloud account come to
[10:40] the top right hand corner here and
[10:42] you’re going to click on download and
[10:43] then you can come back here and click on
[10:46] import from file and then you’ll just
[10:48] basically select that downloaded Json
[10:50] file and then that will import all of
[10:52] your workflows here and then obviously
[10:54] you have to um add your credentials
[10:57] because it’s not going to migrate over
[10:58] the credentials because now you’re using
[10:59] your local machine to run everything and
[11:01] that’s pretty much it so if you already
[11:02] have a bunch of workflows on your cloud
[11:05] account you can migrate them over very
[11:06] easily all right so now let’s go ahead
[11:08] and actually um stop this so that way
[11:10] you see um how that works as well so now
[11:13] if you are done with your workflows and
[11:15] you want to stop uh the container that’s
[11:17] running all you have to do is come to
[11:18] the container and then right here it
[11:20] says stop click on this and it says
[11:23] stopping n8n as you can see in the
[11:25] bottom here and it stopped and as you
[11:27] can see now there’s that option of play
[11:29] button that appears so now if we go back
[11:31] to our local host and refresh this or
[11:35] enter this again reload now it says that
[11:38] this site can’t be reached because
[11:39] obviously our um Ed end container is not
[11:42] running so if you want to run it again
[11:44] you’ll come back click on
[11:46] start and now it says running right so
[11:48] go back to your tab and
[11:52] reload and there you go so that’s that’s
[11:55] kind of the beauty of kind of setting it
[11:56] up once for your account so that way
[11:58] you’re not going to be able to to you
[11:59] don’t have to log in there again because
[12:01] we didn’t set any kind of authentication
[12:04] um so this just makes the process really
[12:06] really smooth so on the next uh tutorial
[12:08] what I’m going to do is go through uh
[12:10] setting up the selfhosted AI starter kit
[12:13] so this is going to be basically similar
[12:15] to what we did earlier but now we’re
[12:17] going to use our um command line um
[12:20] because we’ll be able to install
[12:22] everything within our local machine
[12:24] including AMA and quadrant which AMA is
[12:29] um a software that gives you the ability
[12:31] to run um and interact with large
[12:34] language models that are open source
[12:36] like Mata AI llama languages on your
[12:39] local machine we can actually download
[12:41] these large language models on our local
[12:44] machine and through um llama will be
[12:46] able to interact with them and then also
[12:48] quadrant is another Vector store
[12:51] database uh that you can self host and
[12:53] be able to therefore interact with
[12:56] everything within your local environment
[12:58] so we’ll go ahead and do that tutorial
[13:00] next because this will give you like an
[13:01] entire package uh for self-hosting your
[13:04] AI workflows all right well hopefully
[13:07] you found this helpful again this is a
[13:08] super easy way to uh set up and run an
[13:11] andent through your local machine
[13:13] without the need to ever touch the
[13:15] terminal or put any kind of code because
[13:17] a desktop version of Docker is amazing
[13:19] it just really gives you a great user
[13:21] interface to be able to interact with it
[13:23] and stop or uh start your container
[13:26] every time you want to run n then from
[13:28] your local machine machine all right
[13:29] well thanks for watching don’t forget to
[13:31] subscribe and like the video because
[13:33] there’s a lot of upcoming great
[13:34] tutorials that I have in mind if you
[13:36] have any particular automation or
[13:37] tutorial that you want me to do please
[13:39] go ahead and put it in the comments
[13:40] below and I’ll see you on the next one
[13:53] [Music]