grafana-to-ntfy conf
This commit is contained in:
parent
02596b8624
commit
03c2ff373d
3 changed files with 75 additions and 20 deletions
8
Taskfile
8
Taskfile
|
|
@ -12,9 +12,9 @@ build() {
|
|||
|
||||
dump() {
|
||||
build "$@"
|
||||
if [ -a "vm-$1.nix" ]; then
|
||||
if [ -e "vm-$1.nix" ]; then
|
||||
sudo cp -f result/vzdump* /mnt/share/proxmox/dump/
|
||||
elif [ -a "lxc-$1.nix" ]; then
|
||||
elif [ -e "lxc-$1.nix" ]; then
|
||||
sudo cp -f result/tarball/nixos-system-x86_64-linux.tar.xz "/mnt/share/proxmox/dump/$1.tar.xz"
|
||||
fi
|
||||
}
|
||||
|
|
@ -24,9 +24,9 @@ get-ip() {
|
|||
if [[ "$file" = "proxmox" ]]; then
|
||||
echo 192.168.0.3
|
||||
return
|
||||
elif [[ "$file" != *.nix && -a "vm-$1.nix" ]]; then
|
||||
elif [[ "$file" != *.nix && -e "vm-$1.nix" ]]; then
|
||||
file="vm-$1.nix"
|
||||
elif [[ "$file" != *.nix && -a "lxc-$1.nix" ]]; then
|
||||
elif [[ "$file" != *.nix && -e "lxc-$1.nix" ]]; then
|
||||
file="lxc-$1.nix"
|
||||
fi
|
||||
grep ip4 "$file" | grep -Po "[0-9]+(\.[0-9]+){3}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue