- Deploy new home asssiant
- Edit deployment and add custom command: `command: ["sleep", "infinity"]
- Exec onto sleeping pod and delete everything in config dir.
eg:k exec -n homeassistant home-assistant-xxx -it /bin/sh` - Use kubectl cp to copy unzipped backup into place:
k cp -n homeassistant . home-assistant-xxx:/configYou may have to hurry as the pod will be restarted as it will be failing its liveliness tests. - Edit the deployment again to remove the sleep command
- Breathe
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| blueprint: | |
| name: Motion-activated Light after Dark | |
| description: Turn on a light when motion is detected and after dark | |
| domain: automation | |
| source_url: https://gist.githubusercontent.com/grantstephens/1c1bf0617316f7780ce53eae271975cc/raw/2f584e55ef76b652b2716b2577261043f1391cfb/motion-light-dark.yaml | |
| input: | |
| motion_entity: | |
| name: Motion Sensor | |
| selector: | |
| entity: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { pkgs, modulesPath, ... }: | |
| { | |
| security.acme = { | |
| acceptTerms = true; | |
| defaults.email = "~your-email-here~"; | |
| }; | |
| networking = { | |
| hostName = "mastodon"; | |
| hostId = "3e55fdff"; | |
| firewall = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ds.channel4.com | |
| cdn.http.anno.channel4.com | |
| cdn.ss.anno.channel4.com | |
| channel4.com.112.2o7.net | |
| channel4.com.sc.omtrdc.net | |
| channel4.com.ssl.sc.omtrdc.net | |
| ic.channel4.com | |
| monitor.channel4.com | |
| sexperienceuk.channel4.com | |
| webstat.channel4.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "context" | |
| "net" | |
| "github.com/ClickHouse/clickhouse-go/v2" | |
| ) | |
| func main() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| ) | |
| func greatestCommonDenomenator(x []int) int { | |
| gcd := func(a, b int) int { | |
| for b != 0 { | |
| t := b |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| esphome: | |
| name: ashp | |
| esp32: | |
| board: nodemcu-32s | |
| wifi: !include wifi.yaml | |
| api: | |
| logger: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "esphome.h" | |
| #include "Wire.h" | |
| #include "Adafruit_GFX.h" | |
| #include "Adafruit_IS31FL3731.h" | |
| Adafruit_IS31FL3731 ledmatrix = Adafruit_IS31FL3731(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "archive/zip" | |
| "compress/gzip" | |
| "encoding/json" | |
| "fmt" | |
| "io" | |
| "io/ioutil" | |
| "math" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| func IsIPv4Net(host string) bool { | |
| valid := net.ParseIP(host) != nil | |
| if valid { | |
| return !strings.ContainsRule(host, ':') | |
| } | |
| return false | |
| } |
NewerOlder