pandapaws.blog

Bits, pandas and sparks

  • test-cache

    March 26, 2025

    Test

  • EdgeOS local DNS resolution

    August 14, 2023

    I have a few local services that I access through subdomains configured in CloudFlare’s public DNS. This is pretty useful specially if you, like me, don’t want to run your own DNS server locally.

    I expose a S3-like service publicly that I turn on/off when friends want to access so that means that when I access it I go through the Internet and back to my local network, less than optimal when moving big data packets.

    I though about setting a second ingress there (this service runs on top of TrueNAS, in a single-node K3s cluster) but that’s another thing that I need to maintain and can break.

    Luckily, I use an EdgeRouter X SPF so I can use that to overwrite DNS requests to specific domains. It works wonders, no more editing /etc/hosts for me.

    This is my config. First, if you use DHCP, make sure that you set the router’s IP as DNS servers. I put 1.1.1.1 as second NS, in case this breaks.

    # Up the cache size a bit
    set service dns forwarding cache-size 250
    
    # Set system DNS servers and use them
    set system name-server 8.8.8.8
    set system name-server 8.8.4.4
    set service dns forwarding system
    
    # Set your local adddresses
    set service dns forwarding options address=/foo.bar.com/192.168.1.XXX
    
    # Save and check
    commit
    save
    exit
    
    show dns forwarding nameservers
    -----------------------------------------------
       Nameservers configured for DNS forwarding
    -----------------------------------------------
    8.8.8.8 available via 'optionally configured'
    8.8.4.4 available via 'optionally configured'

    And that’s it. Now when I do an aws s3 sync locally I go directly to my NAS instead of going through the Internet.

    You can check out official docs on how to access the configuration console for EdgeOS on this link.

  • Don’t let the doggo trick you

    March 15, 2023
    Automations, Home Assistant, Voldo

    High food drive dogs are always hungry, they’ll do anything to get a refill, even lie to your face.

    Voldo is one of those, “did you feed the dog?” is a common question around the house and more often that we would like to admit he manages to double-dip.

    How could you say no to that face?
    (more…)
  • Stop killing your plants

    December 22, 2020

    Lately I’ve been in an automation spree around the house. Since COVID-19 we’ve been working from home and spending most of our time indoors, so it makes sense that all the projects we had gathering dust are becoming important again.

    In future posts I’ll talk more about what I’m using to drive my IoT devices, but the core of it all is a Home Assistant instance running inside my FreeNAS (now TrueNAS) server, in a Virtual Machine with Home Assistant Operating System.

    This gives me access to the official Add-on Store and runs everything seamlessly, without fear of breaking everything up on an upgrade.

    I’ve got a few wall switches, some plugs, LED strips and bulbs… everything running the latest Tasmota. Tasmota is an Open Source firmware that can be installed on almost all Chinese IoT devices that are running inside an ESP8266 (think of it like an Arduino with integrated WiFi).

    Tasmota works great, and in latest version it integrates directly with Home Assistant. Older versions needed an MQTT server to broker messages to and from the devices. If you’ve never used MQTT you’ll find it similar to an email inbox and outbox, where your device sends messages to Home Assistant (ie: I turned myself on) and Home Assistant leaves messages for your device (ie: Turn yourself on).

    Home Assistant integrates with MQTT as a way to communicate with a lot of stuff, not only with Tasmota devices, but with basically anything that can send messages in a format HA understands.

    (more…)
  • Rechargeable AAA batteries

    July 21, 2020

    I recently found out about the existence of rechargeable 1.5V AAA batteries. Most people don’t know that normal NiMH AA or AAA batteries don’t output 1.5V like a normal Duracell battery would.

    NiMH AA/AAA batteries are rated to 1.2V but they’ll give you 1.4V when fully charged and start dropping their voltage when they start to deplete.

    The chinese company Kentli sells 14500 format Li-ion batteries that include a buck converter that will drop the 3.7V a Li-ion battery gives to 1.5V. The form factor is the same as a normal AA/AAA battery and they’ll work in most appliances.

    Medtronic 722 insulin pump
    (more…)
1 2
Next Page→

Proudly Powered by WordPress