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: Smart Charging (light) 🔌📱 | |
| description: > | |
| Automatically turns the socket on and off for phone charging. | |
| If the battery level is low — the socket turns on, or based on a schedule. | |
| When the battery reaches 100%, the socket turns off. | |
| domain: automation | |
| input: | |
| charge_socket: | |
| name: Charging Socket 🔌 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
| # WARNING: Requires ROSE-storage package installed and "backups" slot mounted | |
| # backup password | |
| :local backupPassword "Extr@Me9@5uerP@55w0rD!"; | |
| :if ([:len [/file find name="backups"]] = 0) do={ | |
| :error "Storage 'backups' not mounted! Mount storage first." | |
| } | |
| # get current date |
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
| # backup password | |
| :local backupPassword "Extr@Me9@5uerP@55w0rD!"; | |
| # ftp params | |
| :local ftpip "192.168.255.100"; | |
| :local ftpuser "mikrotik"; | |
| :local ftppassword "SuperMegaPass1337"; | |
| :local ftppath "/path/to/backups"; | |
| # get current date |
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
| # backup password | |
| :local backupPassword "Extr@Me9@5uerP@55w0rD!"; | |
| # ftp params | |
| :local ftpip "192.168.255.100"; | |
| :local ftpuser "mikrotik"; | |
| :local ftppassword "SuperMegaPass1337"; | |
| :local ftppath "/path/to/backups"; | |
| # months array |
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: Smart Charging (switch) 🔌📱 | |
| description: > | |
| Automatically turns the socket on and off for phone charging. | |
| If the battery level is low — the socket turns on, or based on a schedule. | |
| When the battery reaches 100%, the socket turns off. | |
| domain: automation | |
| input: | |
| charge_socket: | |
| name: Charging Socket 🔌 |
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
| #!/bin/bash | |
| # Define the Java versions and their download URLs | |
| declare -A java_versions=( | |
| ["7"]="https://download.java.net/openjdk/jdk7u75/ri/openjdk-7u75-b13-linux-x64-18_dec_2014.tar.gz" | |
| ["8"]="https://cdn.azul.com/zulu/bin/zulu8.74.0.17-ca-jdk8.0.392-linux_x64.tar.gz" | |
| ["11"]="https://download.java.net/openjdk/jdk11/ri/openjdk-11+28_linux-x64_bin.tar.gz" | |
| ["17"]="https://download.java.net/openjdk/jdk17/ri/openjdk-17+35_linux-x64_bin.tar.gz" | |
| ["21"]="https://download.java.net/openjdk/jdk21/ri/openjdk-21+35_linux-x64_bin.tar.gz" | |
| ) |
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
| # Temporarily add a normal upstream DNS resolver | |
| /ip dns set servers=1.1.1.1,1.0.0.1 | |
| # CA certificates extracted from Mozilla | |
| /tool fetch url=https://curl.se/ca/cacert.pem | |
| # Import the downloaded ca-store (127 certificates) | |
| /certificate import file-name=cacert.pem passphrase="" | |
| # Set the DoH resolver to cloudflare |
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
| #!/bin/bash | |
| ################################################### | |
| # How to use: | |
| # | |
| # $ podman-update.sh [--force] container_id (OR container_name) | |
| # optional: | |
| # --force: force update even if the image is up to date | |
| ################################################### |
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
| def keys_to_int(data) -> dict: | |
| return {int(k): v for k, v in data.items()} |
NewerOlder