Install Nextcloud on a RaspberryPi With Docker! Easy 5 Steps

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone and welcome back to another video now in this video i'm going to show you how to set up next card running on a raspberry pi and this will be set up and running in docker which is fantastic so just quickly in a nutshell what next cloud is if you're still trying to wrap your head around it it's just a storage service that you can actually run yourself on uh your own bit of hardware so you can run on a server and a cloud server uh you can run it on a you know a desktop that you've got or whatever but in this case we'll be running it on a raspberry pi the great thing about next cloud is that it's all open source so let's just zoom in a little bit as you can see here this is the source code for next cloud so you can come in here make changes you know you can do whatever you want with it and that's great if you're kind of security conscious and privacy conscious about where all your storage and your data is saved so yeah this is just a great alternative to using those big cloud providers uh like dropbox and stuff like that so hosting yourself fantastic right because you know where everything is stored so in five steps we should be able to get this all set up so i'm going to cover what you need um installing docker i'll show you how to do that mounting an external drive making folders for the next cloud docker command and then we will run the docker command so let's start at step one so what do you need well you're going to need a raspberry pi and i'm going to assume that you have it all set up with a distribution i am running raspberry pi os formerly known as raspbian and i also have an external hard drive plugged in so let me show you kind of what my setup looks like i don't know if you can see it i have my mic cable in the way i apologize about that but um i don't really have anything set up to record my desk but i have a raspberry pi here and an external hard drive sitting underneath it so you can just use the raspberry pi if you like but i do recommend using an external hard drive so that's what you need to do to be able to do the setup so next step is installing docker so let's go ahead and get that done so no surprises here what we're going to need to do is ssh into our raspberry pi once you've ssh into it what we can do is install docker so it's pretty simple the command will be in the description but just follow along so with sudo apt install docker and we'll install docker compose as well and then just hit enter and this will install but as you can see i have those two services already installed but if you don't just wait for that to install and then you'll be able to follow us in the next step so what's our next step mounting an external hard drive okay that's fine so if you are using an external hard drive follow this step if you're not um there might be a tam stamp in the description or something so you can skip the stage so if you are using an external hard drive what you need to do is actually mount that external hard drive so first off we need to find out where it is so you can do this by running fdisk first when you do sudo fdisk hyphen l so this is just listing all your disks that are that your raspberry pi can see so if we have a look here we can see this is our uh sd card that our raspberry pi os is installed onto but then we can see this one here which is my external hard drive and it's all plugged in and ready to go um so as we can see it's mounted on dev sda1 so let's mount that to our folder um so all we need to do is create a folders for this and then we'll mount it so what we'll do is we'll clear this up and i'll show you how to do that so what you want to do is make a directory um where you want your external hard drive to be mounted to so what we need to do is go forward slash and then wherever you want so you can do it where i'm making mine so forward slash mount um and then let's just call it external but we're gonna need to put sudo on that so we've just made a folder called external and now we can mount rsd uh sorry external hard drive onto that so the easiest way to do that is just to do mount div sda1 because that was the name of the drive and then we want to mount to external and then you would run that command i have mine already mounted somewhere else but oh that's all you need to do right so i will show you that i have my mounted just for peace of mind so sudo mount dev sda1 onto mines on media usb i believe and i hit enter and as you can see here that's where mine is mounted so you can essentially mount it in any folder as long as it just makes sense of where it's actually been mounted cool so um that is step three done for how to mount an external drive uh now just bear in mind so after the restart say if you restarted your raspberry pi frictional hard drive it will that mount will be forgotten so you either have to mount it again using the same command or you can add it into a file so then it is automatically mounted on startup i'll leave a little link in the description how to set that up otherwise this video will be taking for ages just to get over to how to install next cloud so step four we need to make folders for next cloud so the easiest way for us to realize what folders we need to make for the docker command to work is by looking at the docker command so as you can see here this is the command we will run so it's actually pretty simple we're just running docker telling it to create a container called next cloud and um we will be running this on port 80. so when i say also when i say name this is using the next cloud image and this is where we're naming it down at the bottom so all we're doing here is mounting some volumes for next cloud to work so what we're saying is this local directory on my raspberry pi will be mounted to this directory on the docker container for next cloud so this here is the folders location that we are going to make okay so this is the only part of the command that we would need to change so we'll just come in here and replace these with where your folder locations will be so let's go ahead and set all of this up so it makes sense right so i'm going to have this side by side so it just makes a lot more sense for you so what we're going to do is actually have a location where our files are mounted for our next cloud so on part uh when we're making setting up the external hard drive we made a directory so let's just change into it called um mount external right so we have this directory and this is the one we will use for our next club so what you want to do is make so this is where we are mount external mount external but we just need to make these folders here next cloud apps config data and theme so let's quickly do that by doing sudo make directory clicks club right and then sudo make directory apps you can see where we're going with this right so we just have to make all of these so i'll see you once i've done that cool so we've run all the commands let me clear this up and i'll show you so alice and now we have apps config data next cloud and theme so one two three four five one two three four five now we have all the folders so now we can mount our local files to our docker container so docker can use our designated location for storage that's all we were doing right so let's go and do this so let's copy this and we'll paste it into our terminal so i'm just going to right click hit paste and as you can see it's going to run sudo docker and it's going to mount all those volumes so i just hit enter and docker has now spun that container up so let's just make sure it's running so we can do sudo docker container alice python a so that's listing all our containers now you can see here that 15 seconds ago it was created and it is up on port 80. so now all you need to do is find the ip address of your raspberry pi that you're connected to at the moment and if your ec station to it you obviously know what the ip address is and just put that into your browser so for me -192.168.1.212. and if i hit enter bam this is our next card instance um and all we need to do now is create an admin account so let's just call this tick docs uh admin and i'll give it a password super strong it's not abc one two three four five uh and then you can choose to install the recommended apps if you like um and then hit finish setup so just click that and now what it's going to do is it's just going to start setting up your next cloud for you so if you're curious you want to see this working in action you can actually come here alice change into maybe your next cloud and do an ls here and now you can see files in here right it's using those folder locations you made that docker instance is writing to those files so at the moment it's just setting everything up just getting those recommended apps and stuff installed for you and we'll just let it do its thing cool so as you can see now it's just jumped into the next page recommended apps installing this installing calendar um so this is where we can actually set up our own meetings and stuff and don't have to worry about google calendar it's all you know your own personal calendar which is fantastic um and setting up i don't even know how to pronounce it calabro collabora i have no idea um to edit office documents and then contact so you can have your own context and talk so you can have your own like chat at with your like internal family or whoever you give access to with the next card you know it's your own internal little g suite or um you know what's the microsoft one onedrive sort of stuff it's fantastic what we'll do we'll just leave this to install its apps and we'll be right back now just quickly while this is actually installing i did want to kind of explain something so if i open up that command we ran see how i've got it mounted on port 80. you can actually run this on any port you like so you could run it on like um on your actual raspberry pi host so here we could have changed this to um 8080 so if we wanted to connect to via our raspberry pi ip address and then 8080 because you're already running something like a web server on your raspberry pi you can do that you can change whatever port you want it mounted on on this side here this side is the docker side so don't change that but here we can change it to whatever we like so i could you know mount on 8080 and then it's there and then i also have my web server or something so feel free to change that port if you like but otherwise leave it on port 80. right so our next cloud has been set up so as you can see here once on a successful setup you'll see next cloud hub open up and a little arrow here so we click across and you can see here that you know you can host your data and files where you decide um 100 open source and community focused there's over 100 apps so again there is like an app store for this so you can go through the app store and look up all these community apps and stuff that you want to set up yourself so as you can see here you can have a music player your own password manager a kanban app all this cool stuff that you can do yourself and then they do have a desktop app google play and a app store uh apple app store uh application so that's the one i was showing you before so where's my phone on sick so as you can see this is nix cloud running on my phone so all my files and stuff like that are all accessible from my phone and again here's just some other stuff that if you want to help contribute to this project you can do that and then there's also enterprise support so if you're running this for your business and stuff like that so once you're all finished reading we can hit start using next club and bam here we are this is our environment so as you can see here we have a dashboard which is just like a quick overview of yours uh nexsad files so if we click here this will load up all where we can save our stuff like that um just pretty typical stuff so we can add files here you know click and drag uh at work so if i wanted to grab a file from my desktop and put it into here i can let me show you that so what i'm going to do is i'm going to make a new file a text document test enter click and drag and we'll paste that into i don't know documents now if i click on documents test you know just like that it is your own cloud storage it's fantastic well i say cloud it technically is cloud because cloud is just someone else's computer but yeah um photos you can host your own photos so if you use the phone app you can have your phone sync all its photos and stuff straight to your raspberry pi to your next club um talk which is that app so it's like that chat app so if other people in your family are using next cloud you can all talk to each other fantastic contacts here you can add just your general contacts um and calendar here you can set up your own calendar and stuff like that as well awesome really really cool and you can also import stuff as well i'm not going to go over how to use next cloud like integrate detail but what you want to do is you'll find out that you actually set up as your admin so what you want to do is actually come into users and you want to create yourself a new user the main reason for that is you don't want to do everything on your admin account because your admin account has full control over the next cloud environment like installing apps and stuff like that where a general user doesn't have those sort of permissions unless you give that user those permissions so for the sake of this video let's make a new user username uh tick docs display name neck password let's give it a password uh email address um i don't know uh we'll just put a random email address example dot example at example dot com um and then if you had like user groups so like we've got that admin so if we wanted this person to be an admin we could add them to the admin group but i'm not going to i can't remember what the password was that i just see it so let's just set a proper one and let's click the tick and then once that account is all set up we can actually log into that account so let's click on this and log out and now let's log into that user i just made cool so we're just logged in to that new user good afternoon nick and this is now my account so if you want to make accounts for your family and stuff this is where you can do it now there's so much customization you can do with next cloud i'm not going to cover it but this is pretty much how you get started uh you can go on to nyx cloud and look for the desktop client to install the client go onto the app store or google play store or whatever to download the phone app you know and then you sync it all and connect to it using your local ip address now talking about your local ip address that's where we talk about how the connectivity and stuff works with your next cloud setup so as you can see here we're using a local ip address are we so what happens if you want to connect to this while you're not at home well you're going to need a vpn setup so i actually have a vpn setup that's running on a raspberry pi so i can connect to my raspberry pi when i'm away from here like away from home and then since i've connected to my raspberry pi i have connection local connection to my home so that's how i can connect to my next cloud do you want to have a vpn setup for your home network um if you don't know how to set all that stuff up actually leave a comment in the description if you want help with that because i will make a video on how to set up a vpn connection on your raspberry pi right but that is pretty much nix cloud again you can change all of these logos uh you can change everything about this and make it really your own personal cloud for storage but i hope that was helpful if you've got any questions please ask below but thank you so much for watching please subscribe if you are enjoying these videos because it really helps me know that you guys are enjoying the videos um but yeah thank you and i'll see you in the next video bye you
Info
Channel: Techdox
Views: 22,560
Rating: undefined out of 5
Keywords: nextcloud, raspberry pi, nextcloud raspberry pi 3, nextcloud raspberry pi, raspberrypi, raspberry pi nextcloud install, raspberry pi 4, raspberry pi 3, raspberry, raspberry pi nextcloud, nextcloudpi, nextcloud box and raspberry pi 3, raspberry pi nextcloud server, how to setup nextcloud on raspberry pi, nextcloud raspberry pi 4, nextcloud raspberry, nextcloud snap raspberry pi, nextcloud box and raspberry pi 2, nextcloud respberry pi
Id: RkJuAGCKsUQ
Channel Id: undefined
Length: 16min 39sec (999 seconds)
Published: Sun Feb 07 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.