I have made too many projects in my lifetime, and thought that a repository is not enough to handle support for them. I also believe that to be able to dump my mind from time to time keeps myself on track. I make projects because I like to help people with problems that may or may not be an issue, now or in the future.
OpenSpeedTest
OpenSpeedTest is basically a speed test in your web browser you can run locally. It is used most commonly to verify the practical throughput from one host to another. Though, it is far from perfect, and you cannot use it for any host or service. For that it is better to use iperf3. But it works for any device having a web browser.
While using it I found two issues that made the result quite interesting and one weary on both client and server configs. For the server, they specifically say that if used with a reverse proxy one needs to make sure that the post body size is larger than 30MB, or more specifically 35MB. Some additional changes are disabling logs and gzip, and avoiding https. One would assume more cores and RAM could be beneficial, but as the project is static files and client script, it isn’t actually an issue at all.
Ansible: VyOS v2
I mentioned over a year ago about the collection in Ansible I used for VyOS. I had some issues with it regarding differences and performance, so I had to resolve to some odd workaround which was ugly(clear config path and recreate from scratch, which was very slow on big configs), but quite easy to use directly with VyOS. I later on made some custom templates for it to reduce boilerplate and coupling. I later found out that the collection, while being maintained (but never updated on Ansible Galaxy) was supporting VyOS 1.1, which is odd as the stable one is 1.3, and the newest is 1.5 since a couple of months ago. I also learned that VyOS had a builtin API. Therefore I went on to integrate with the API and Ansible, creating a role with some local actions.
What now
A couple of days ago I found out by my teacher that they skipped the next round of opposition(I think that’s how you translate it), so I have to start all over in the next course starting next week. While they will be more strict this time around, needing to be more specific regarding the research question, I can still reuse most of my current work. Hopefully I can even finish writing earlier due to this, but I have no idea what the future holds. For you who reads this, it only means that you will be able to engage in my content for a bit longer, maybe more details regarding my work.
Block Color Config
I happened to see a boosted post on Mastodon, where someone mentioned that most programs handle their configs badly, basically generating full configs, maybe with commented out options and defaults, which upon updates will be rendered worthless if they change. I responded to how I handle my configs, and suggested an alternative solution, which I implemented.
The first version of PixelMap 0.x had all configs statically added to the program, meaning they cannot be changed after the program is compiled. Later on I designed a block color format, where a config file could be added and therefore change the colors of the created images. PixelMap 1.x had the block color file added per default, but if it wasn’t provided, defaults were transparent, meaning the resulting image could be completely transparent.
What happened
I got sick for a couple of weeks, was lazy and had a hard time getting into the mood to work on it at all. I think I just recently got over it, but it is definitely a struggle to keep on going on this, especially as I’m doing it alone.
But what I’ve done the last couple of weeks is to fix a couple of issues my tutor told me, add 1-99 percentile (or something similar at least), and contemplate the research question. Now on for the result.
Ansible: Release
I forgot to post the above, so a double post! 😄 I released parts of my working Ansible infrastructure, hopefully it can be used and maybe some people want to point out anything that might be problematic: https://github.com/McTwist/ansible-homelab/
This solidifies my integration and allows me to version track my infrastructure. However, I still cannot store my configs, because releasing them would mean I publicize my whole network infrastructure, which would be pretty bad. Even if it does not contain anything that would be problematic, it still is not something that should be released at all. I will eventually come up with a solution, probably storing them on my local git in a local branch that is not pushed or something.
Ansible: PHP
As previously mentioned, I created a couple of roles and a playbook to bundle them together. For the last 2 weeks I have been fixing bugs, but it is currently in a state where it is stable to even be released. While I do think that the coupling between the roles might be too tight, I need to split two roles into more sub-roles for it to work properly.
One of the roles, php-fpm, is used to handle the PHP part of the server. It basically takes in a list of PHP objects containing version, modules and pool variables. With some dictionary juggling and set theory, it will generate two lists from gathered modules: modules to be added; modules to be removed. With these lists it is just a matter to process them in the right order: add new modules and then remove old ones. All this is done for pools too.
Reverse Proxy
A reverse proxy is a service which a client can connect to and it’ll forward all connections to respective service, usually internally. This is mostly used for HTTP requests, where the reverse proxy will handle the default ports, certificates and hosts to keep track on. All requests are then forwarded to an internal web server, or any other server that supports HTTP. It separates the direct access to services and makes it possible for one IP to be used with several services. There are many programs for this, some that are full blown web servers.
Syncthing
Syncthing, a distributed file sharing service. Usually you just fire it up, input the ID from another device and suddenly they are connected and can share folders, files being transferred like any other cloud service. However, each device still need to find each other, so a discovery server is necessary, which several are provided by default. Then comes the transfer of the files, if you are on the same network, they can figure this out and connect automatically. But if both are behind a NAT, there is no way to transfer. Therefore relay servers are a necessity, providing a bridge over the NAT.
Hardware passthrough
This is not related to the homelab itself, but specifically to Proxmox and passthrough of hardware. I, as mostly everyone, have been for years been using Windows on a PC to play games. This have worked very great, but for the past 5 years (or more), M$ have been doing some shading things and design decisions that have made me want to move from them. The problem is that I am both unsure how gaming on Linux works, and if it will work for a bunch of games that I play daily. I thought that maybe dual boot would work, but the problem there is that Windows are known to trash the boot loader after an update, at least if it is on the same partition. And what if something breaks? Therefore I came to the conclusion that I should virtualize it.