dotfiles/.config/bash/pve.bash

15 lines
339 B
Bash
Raw Normal View History

2023-11-15 19:49:25 +00:00
[[ $- == *i* ]] && zfs list -d 0
alias cluster='scr corosync && scr pvesr'
qcow() { qemu-img convert $1 -O qcow2 ${2:-$1}.qcow2; }
extrac() {
for var; do
arg=${var%.lzo}
out=$(basename ${arg%.vma})
lzop -x $arg.lzo
vma extract $arg $out &&
( cd $out && find *.raw -exec qemu-img convert {} -O qcow2 $arg-{}.qcow2 \; )
done
}