Skip to content

Instantly share code, notes, and snippets.

View webknjaz's full-sized avatar
🇺🇦
#StandWithUkraine: https://github.com/vshymanskyy/StandWithUkraine

🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) webknjaz

🇺🇦
#StandWithUkraine: https://github.com/vshymanskyy/StandWithUkraine
View GitHub Profile
@webknjaz
webknjaz / signoff
Created May 6, 2024 21:52 — forked from dhh/signoff
#!/usr/bin/env bash
# Abort sign off on any error
set -e
# Start the benchmark timer
SECONDS=0
# Repository introspection
OWNER=$(gh repo view --json owner --jq .owner.login)
@webknjaz
webknjaz / openwrt-network-access-recovery.md
Last active March 1, 2024 00:51
These are some hints on how to reach an OpenWRT dumb AP with link-local IPv6 when IPv4 fails
@webknjaz
webknjaz / smart-home-mesh.md
Last active December 12, 2023 15:09
Smart Home | Home Assistant | Zigbee research

💭 Thoughts

I want to have:

  • an HA instance deployed to my k8s cluster made of 3 Raspberry Pi nodes
  • a mesh of Zigbee devices covering both floors of my house
  • minimized interferrence with the 2.4 GHz band Wi-Fi channels

🔎 Findings

  • a Zigbee network requires a device called coordinator
  • there may be only one Zigbee coordinator per network
@webknjaz
webknjaz / README.md
Created June 27, 2023 22:00
Testing CherryPy's TLS setup

The provided below cp_tls_builtin.py and cp_tls_pyopenssl.py modules are almost bare minimum CherryPy apps set up to serve a static string over HTTPS. I say "almost" because having an HTTP handler mounted isn't really necesary to verify that TLS works but having it provides a nice visual cue when using curl, for example.

This instruction assumes that you have a freshly made virtualenv where you executed something like pip install 'CherryPy[ssl]' trustme. The ssl extra is only needed to pull in pyOpenSSL and isn't needed for the built-in stdlib TLS adapter. The trustme project is needed for demonstration purposes — it'll

@webknjaz
webknjaz / macos-13-under-parallels-18.md
Created March 7, 2023 15:53
Observations and gotchas of running macOS 13 guests under Parallels Business 18
  1. When using Parallels' port forwarding feature with the virtio network adapter under the Parallels hypervisor, the transfer rate is so slow that it takes almost 5 minutes for a 1MB file to go through. Connecting to the VM port directly, not through the forwarded port, does not exhibit the bug. Switching to a different adapter or changing the virtualization to Apple fixes it.
  2. Under macOS 13, using any network adapter other than virtio, makes networking completely non-functional. So switching the hypervisor is the only workaround available.
  3. When the number of allocated CPUs is shrinked down to 1, the Settings window may become unresponsive or parts of the settings are unavailable/grayed out. I couldn't see what apps have full disk access, for example. Increasing the CPU number to 2 makes it work. 1-CPU VMs are enough for the CI, though.