diff --git a/index.html b/index.html index 18f9d17..3405198 100644 --- a/index.html +++ b/index.html @@ -148,7 +148,7 @@ callFrame.src=user_string;
I accept donations for any reason
-Thursday 19/12/24 19:13:11 +Thursday 19/12/24 19:44:15 11
DATE: Thu 19 Dec 2024 18:35 By: konsthol@pm.me
Years ago, some good friends of mine gifted me for my birthday, a -Raspberry Pi 4 with 2GB of ram. It was and still is the most thoughful -gift anyone has ever gotten for me. It aligns perfectly with my hobbies -and I used it for a long time as a VPN server using WireGuard and I also -played around with Pi-hole for a while as a network-wide ad blocker.
-Eventually I became more interested in cloud computing and started -self hosting many services on a VPS that I rent through MVPS. It has 4GB -of ram and has currently many of the services I use in a day-to-day -basis like my Gitea server, Searx, NTFY and many others. While it was -definetely doable for the Raspberry Pi to host these, the 2GB of ram -would not allow for every service to be run at the same time. You see, -my friends were lucky to even find one because it was in the middle of -the chip shortage problems.
-One day as I was thinking about what kind of projects could I utilize -a single Raspberry Pi for, it hit me. A simple Wake-On-LAN server. It -requires almost no resources as it just needs to stay on and send out -wol packages when I need it to. The Raspberry Pi is connected using -Wi-Fi to the same network as my laptop. Usually if I wanted to wake my -laptop up using Wake-On-LAN I would need to have it plugged with an -ethernet cable with the router. However, the Raspberry Pi has an -ethernet port and a cable has two ends. Which lead me to try to connect -one end to the Pi and another one to the laptop. At first I begun with a -simple shell script that used etherwake. A simple command-line tool that -sends Wake-On-LAN Magic Packets. It worked like a charm. I had enabled -Wake-On-LAN in my laptop’s BIOS, it was enabled on the operating system, -which I checked using ethtool and it was super easy to remotely wake my -laptop up using a Termux shortcut on my phone which used ssh to connect -to the Raspberry Pi and from there execute the etherwake command.
-That setup was wonderful but I wanted to make it even better. It -wasn’t actually a Wake-On-LAN server at this point. The only service -that was running on the Pi was SSH and I just used a command to wake -just my laptop up. So after some research I came across Flask. With -Flask I managed to make an actual server that used routes, -authentication, logging rate limits and everything needed to make it -robust, secure and functional. The main reason I currently prefer my -project over etherwake, even though etherwake is still a great tool that -follows the Unix philosophy “Do one thing and do it well”, is because of -it’s dynamic nature. I can configure a .env file with many device’s MAC -addresses and have as many possible routes as the number of the devices. -So for a laptop and a desktop I have LAPTOP_MAC=“itsmac” and -DESKTOP_MAC=“itsmac” and can wake them up using http requests in the -route /wol/laptop and /wol/desktop respectively.
+Years ago, some good friends of mine gifted me a Raspberry Pi 4 with +2GB of RAM for my birthday. It’s hands down the most thoughtful gift +I’ve ever received, perfectly matching my hobbies. They were lucky to +even find one during the chip shortage! I initially used it as a VPN +server with WireGuard and played around with Pi-hole for network-wide ad +blocking.
+Eventually, I got into cloud computing and started hosting multiple +services on a VPS I rent from MVPS. This VPS, with its 4GB of RAM, +currently runs several of my daily-use services like Gitea, Searx, NTFY, +and more. Although the Raspberry Pi could theoretically handle these +services, its 2GB of RAM limited simultaneous operations.
+One day, it hit me: why not use the Raspberry Pi for a simpler +project like a Wake-On-LAN (WOL) server? It requires minimal resources +and just needs to stay on and send WOL packets. The Raspberry Pi is +connected via Wi-Fi to the same network as my laptop. Normally, waking +up my laptop with WOL would require an Ethernet cable connection to the +router, but I connected one end to the Pi and the other to the +laptop.
+I started with a simple shell script using etherwake, a command-line +tool to send WOL packets. After enabling WOL in my laptop’s BIOS and +confirming it on the OS using ethtool, I could easily wake my laptop +remotely using a Termux shortcut on my phone, which SSHed into the +Raspberry Pi to execute the etherwake command.
+Though this setup worked perfectly fine, I wanted to make it even +better. Initially, the Raspberry Pi only ran SSH and executed a command +to wake my laptop. So it wasn’t really a WOL server. After some +research, I found Flask and created an actual WOL server. This server +had routes, authentication, logging, rate limits, and more to ensure +robustness and security.
+What makes my Flask-based server so cool is its dynamic nature. I can +configure a .env file with multiple device MAC addresses, allowing +numerous routes for different devices. For instance, I have +LAPTOP_MAC=“itsmac” and DESKTOP_MAC=“itsmac”, enabling me to wake them +via HTTP requests at /wol/laptop and /wol/desktop, respectively.
+One open-source application that fits my use case is HTTP Shortcuts +from F-Droid. After configuring a specific route, I can turn it into a +widget on my home screen. This way, I can wake my laptop up with just a +tap! Plus, I use dynamic DNS, so my Pi is accessible from anywhere.
Mascot
I would suggest anyone to take a look at my project’s repo and if diff --git a/rss.xml b/rss.xml index bb57b92..a944bab 100644 --- a/rss.xml +++ b/rss.xml @@ -14,48 +14,44 @@
DATE: Thu 19 Dec 2024 18:35 By: konsthol@pm.me
Years ago, some good friends of mine gifted me for my birthday, a -Raspberry Pi 4 with 2GB of ram. It was and still is the most thoughful -gift anyone has ever gotten for me. It aligns perfectly with my hobbies -and I used it for a long time as a VPN server using WireGuard and I also -played around with Pi-hole for a while as a network-wide ad blocker.
-Eventually I became more interested in cloud computing and started -self hosting many services on a VPS that I rent through MVPS. It has 4GB -of ram and has currently many of the services I use in a day-to-day -basis like my Gitea server, Searx, NTFY and many others. While it was -definetely doable for the Raspberry Pi to host these, the 2GB of ram -would not allow for every service to be run at the same time. You see, -my friends were lucky to even find one because it was in the middle of -the chip shortage problems.
-One day as I was thinking about what kind of projects could I utilize -a single Raspberry Pi for, it hit me. A simple Wake-On-LAN server. It -requires almost no resources as it just needs to stay on and send out -wol packages when I need it to. The Raspberry Pi is connected using -Wi-Fi to the same network as my laptop. Usually if I wanted to wake my -laptop up using Wake-On-LAN I would need to have it plugged with an -ethernet cable with the router. However, the Raspberry Pi has an -ethernet port and a cable has two ends. Which lead me to try to connect -one end to the Pi and another one to the laptop. At first I begun with a -simple shell script that used etherwake. A simple command-line tool that -sends Wake-On-LAN Magic Packets. It worked like a charm. I had enabled -Wake-On-LAN in my laptop’s BIOS, it was enabled on the operating system, -which I checked using ethtool and it was super easy to remotely wake my -laptop up using a Termux shortcut on my phone which used ssh to connect -to the Raspberry Pi and from there execute the etherwake command.
-That setup was wonderful but I wanted to make it even better. It -wasn’t actually a Wake-On-LAN server at this point. The only service -that was running on the Pi was SSH and I just used a command to wake -just my laptop up. So after some research I came across Flask. With -Flask I managed to make an actual server that used routes, -authentication, logging rate limits and everything needed to make it -robust, secure and functional. The main reason I currently prefer my -project over etherwake, even though etherwake is still a great tool that -follows the Unix philosophy “Do one thing and do it well”, is because of -it’s dynamic nature. I can configure a .env file with many device’s MAC -addresses and have as many possible routes as the number of the devices. -So for a laptop and a desktop I have LAPTOP_MAC=“itsmac” and -DESKTOP_MAC=“itsmac” and can wake them up using http requests in the -route /wol/laptop and /wol/desktop respectively.
+Years ago, some good friends of mine gifted me a Raspberry Pi 4 with +2GB of RAM for my birthday. It’s hands down the most thoughtful gift +I’ve ever received, perfectly matching my hobbies. They were lucky to +even find one during the chip shortage! I initially used it as a VPN +server with WireGuard and played around with Pi-hole for network-wide ad +blocking.
+Eventually, I got into cloud computing and started hosting multiple +services on a VPS I rent from MVPS. This VPS, with its 4GB of RAM, +currently runs several of my daily-use services like Gitea, Searx, NTFY, +and more. Although the Raspberry Pi could theoretically handle these +services, its 2GB of RAM limited simultaneous operations.
+One day, it hit me: why not use the Raspberry Pi for a simpler +project like a Wake-On-LAN (WOL) server? It requires minimal resources +and just needs to stay on and send WOL packets. The Raspberry Pi is +connected via Wi-Fi to the same network as my laptop. Normally, waking +up my laptop with WOL would require an Ethernet cable connection to the +router, but I connected one end to the Pi and the other to the +laptop.
+I started with a simple shell script using etherwake, a command-line +tool to send WOL packets. After enabling WOL in my laptop’s BIOS and +confirming it on the OS using ethtool, I could easily wake my laptop +remotely using a Termux shortcut on my phone, which SSHed into the +Raspberry Pi to execute the etherwake command.
+Though this setup worked perfectly fine, I wanted to make it even +better. Initially, the Raspberry Pi only ran SSH and executed a command +to wake my laptop. So it wasn’t really a WOL server. After some +research, I found Flask and created an actual WOL server. This server +had routes, authentication, logging, rate limits, and more to ensure +robustness and security.
+What makes my Flask-based server so cool is its dynamic nature. I can +configure a .env file with multiple device MAC addresses, allowing +numerous routes for different devices. For instance, I have +LAPTOP_MAC=“itsmac” and DESKTOP_MAC=“itsmac”, enabling me to wake them +via HTTP requests at /wol/laptop and /wol/desktop, respectively.
+One open-source application that fits my use case is HTTP Shortcuts +from F-Droid. After configuring a specific route, I can turn it into a +widget on my home screen. This way, I can wake my laptop up with just a +tap! Plus, I use dynamic DNS, so my Pi is accessible from anywhere.
I would suggest anyone to take a look at my project’s repo and if