Newbie's Journey: AdGuard DNS Issues and Switch State Automation

Hello all, I’m a fresh face diving into the world of smart home automation with HomeAssistant. It’s both exciting and a bit overwhelming, but I’m here to learn and share my experiences.

One challenge I’ve encountered is related to DNS configuration when using the AdGuard addon. My setup involves a Raspberry Pi running HomeAssistant with AdGuard, and my Fritzbox router directs all devices on the network to use the Pi as the DNS resolver. However, this setup occasionally causes issues when trying to update HomeAssistant. The problem seems to stem from DNS resolution when AdGuard is disabled, which I’ve noticed affects the update process. My current workaround is to set a fixed DNS resolver on the Pi itself, directing it outside my local network, while keeping other devices within the network pointing to the Pi. I’m curious if there’s a more seamless solution out there that doesn’t require this workaround. Any insights or alternative approaches would be greatly appreciated!

Another area I’m exploring is scripting within HomeAssistant. I recently learned how to save and restore the brightness of lights using a script, thanks to some helpful guidance from the community. Now, I’m trying to apply a similar approach to saving and restoring the on/off state of a switch. The switch in question controls a traditional light bulb, and I’m wondering if it can be treated as a light entity within HomeAssistant. If not, I’d love to know the best way to handle its state within a script. The goal is to capture the switch’s state at the start of a script and restore it at the end, ensuring that the automation behaves as intended without disrupting the user’s manual settings.

It’s amazing how much there is to learn, but it’s even more rewarding to see the system come together and work smoothly. I’m looking forward to hearing from more experienced users and learning from their tips and tricks. Here’s to many successful automations ahead!