 Okay, we're continuing to look at notify ntfy.sh is the website and today we're going to set the server, which is just, it might be easier than actually using the application, which was super easy to do. And I'm going to go over the basics of just setting up a server. We're not going to go over, you know, security certificates and stuff like that using Let's Encrypt. I'll show you, they have instructions for that, just adding some stuff to the config file. But let's go ahead and look at their website here, ntfy. And I got this set up and I tested it in the shell. I didn't test out the web application or the phone application. So we're going to do that together. Let's go ahead and ntfy docs and off to the side here. They have a bunch of stuff here. We want installation. Okay, so it's under self hosting. So again, you don't have to do this. You can use their servers, but if you do this, why not use your own server? So and I'm just going to do something on my local network. And something else I'm not going to go over is port forwarding. If you're behind a firewall, that's a whole other topic. But if you have a server somewhere up online, super simple here. So look, look, we clicked on this. They have general steps, Linux binaries, Debian Ubuntu repositories, Fedora, Arch, blah, blah, blah, macOS, Windows, Docker. I don't know why I would use all these. Now, I am just going to use the binaries, right? So it's straight binary. It's actually a single binary and two config files, one for the client, one for the server. This is the server one today. I could add the Debian repositories that they have set up because it's not in the default repositories. I hate adding a bunch of extra repositories I don't need. So I'm going to go with just the binary today. The benefit of adding their repository is when there's updates, you'll automatically get updates. If we're doing the binary, we're going to have to check updates for ourselves regularly. So keep that in mind. Look, they already have it compiled for your x86 64-bit processor, so your desktop. But they also have your most common versions of ARM processors here. So you could run this on your phone if you wanted as a server. But let's go ahead. And again, I'm just going to use this right here. And this is the most up to date. If you go to their GitHub page and click on releases and they'll list all the files, they have the binaries, Debian. That's where this is coming from. And as of recording it, 1.291 is the current release. So let's go ahead. I'll just copy that first line. I'm in an empty directory here. I haven't split into three screens because we're going to get the server running and then we're going to monitor it and then we're going to send a message. Let's go ahead and just download that. So it's downloaded. Next thing we're going to do is we're going to untar it. So we're just going to run this again. I'm just going to copy and paste. It's untarred. So it untarred it to the local directory. There's a subdirectory now. There's the file we downloaded, subdirectories. And right here is the binary file. So what we need to do next is copy that to our system directory, one of our path directories. Now they copy it to USR bin. I personally think it probably belongs in USR local bin. But I'm just going to follow their directions for now. Basically USR bin should only be for binaries that are installed by your operating system. If you're installing something manually like this, it should go in USR local bin. It doesn't really matter. But if you're backing up stuff, sometimes backing up your local bin is easier because it's only stuff you know that's not installed by default repositories. I think maybe they do this since you can install, set up their repositories and they're just trying to be consistent. So anyway, what we're going to do is we're going to use sudo because we're going to write to a directory that we're don't normal users shouldn't have access to. So we're going to copy over that binary. So now it's there and it's executable. But we also want to set up the config file. So again, in what we unzipped, we have a client config file and a server config file. So we just make a directory under ETC, like so, which I didn't delete after make it. So let me delete that real quick, sudo remove because I did test this already. I deleted the binary by didn't delete that directory. Okay. So we delete it because I did make one change to the config file. Let's try that again. Okay. So I got to make the directory because I just deleted it. Sorry. I lost track of where I was at. But we're just going to copy over their two YAML files to this directory. So now if I list out what's inside this directory that we just created, we have two YAML files, the client, which again, you can use curl or their client. They have full documentation on their website, but they also have this YAML file. Now next they're saying to run it and to notify server. They're running it as sudo. I'm assuming because by default it's going to try to use port 80, okay, which regular users don't have access to. If I try to run that now, I am going to get an error because I already have a web server running on my machine. I have Apache running on port 80. So we want to change what port we're going to use. And that's simple enough. We're just going to say sudo vim or whatever text that are you like, etc notify. And we're going to go into the server config file. Let's make this full here. And it has a bunch of example stuff in here. We're just going to go down to the bottom. If we go back to their web page and we get past this installation, so we're done with the installation. And again, if you don't have something running on port 80 already, it's going to be running like that. Although I don't like the idea of running it as sudo. There's no need for that. Let's go to configuration. They're going to give you some examples here. And look, you can set up HTTPS. They gave you some examples here. I don't have a URL set up and encryption on this machine. I am going to set this up on a machine that does have a domain name and encryption keys. It shows you what port we're going to listen on. I don't know why it doesn't show you that here. We're going to listen on port 80. If you're using encryption keys, the ports you use are important. So I'm just going to add to this file this, but I'm going to change this to a port that I'm not using. I'm just going to use 7777 because I know that's not being used. I'm going to save that. Now I can run this notify serve command. I don't need to run it as sudo because I don't need special privileges to run on port 7777. Do that. It is running. Great. I can come down here. We can run just like we did before. Let's go back to their main page here and we will go down to their examples. I can send something to a topic. So I can say, okay, backup successful, but we're going to use our local machine. So I'm just going to say local host, and I'm going to give it a topic. I'll just again say FBK. We're using port 7777. Just like any other thing, web browsers or what, the port is just the domain name or IP address colon the port and then forward slash the topic. Okay. We sent it. Let's go ahead and listen to that. So let's go ahead curl dash s. If I remember correctly, I'm doing this from memory. And we're going to say, do I need just to say local host colon 7777 forward slash FBK. JSON. Boom. It's listening. Come back up here and send a message. And there he goes. It shows up down there. Let's go back to our web browser though. And I'm going to go local host colon 7777. And it's running as a web server says single binary is running as a web server here just like their web server, but this is running locally here. And I can subscribe to a topic or I can do just like before I can do forward slash FBK and you can see here that it has those messages. If you look through documentation, they do store the messages by default and you can change all this for a certain number of hours and you can set up attachments as well. I'm going to get into that, but that's all in the documentation. So the web browser is working locally. Let's go ahead and look at my mobile device. So we're going to go into here and we're going to open up here. I already have some using their server. I'm going to click here. I'm going to do FBK and I'm going to say use another server. I'm going to use my local server. So HTTP colon forward slash forward slash and going to give it my IP address 192.168.1.154 I think is my IP address colon 7777 subscribe. I haven't done this yet. Let's see if this works. No 55 subscribe. There we go. Look at that. Oh, you're not looking at it. Look at that. So super simple. Let's do that again. Let's go back. Let's subscribe to another one. We're going to say use another server there. There we go. Subscribe. I actually remembered. And now let's go back here. Let's go here and we're going to send a message and we said tester. There we go. It came through on my mobile device. Yay. How simple was that? Doing with my little hiccups there here and there. I thank you for watching filmsbychris.com. That's Chris of the K. There's a link in the description. As always, please visit my website to think about supporting, liking, share, subscribing and I hope that you have a great day.