Use nix-output-monitor in all scripts
This commit is contained in:
parent
ab866b4965
commit
3d32f750f0
|
@ -79,7 +79,7 @@
|
||||||
format-modules = "nixpkgs-fmt **/*.nix";
|
format-modules = "nixpkgs-fmt **/*.nix";
|
||||||
nix-generations = "sudo nix-env --list-generations --profile /nix/var/nix/profiles/system";
|
nix-generations = "sudo nix-env --list-generations --profile /nix/var/nix/profiles/system";
|
||||||
rebuild = ''
|
rebuild = ''
|
||||||
nixos-rebuild -j auto switch --use-remote-sudo
|
nixos-rebuild -j auto switch --use-remote-sudo |& nom
|
||||||
'';
|
'';
|
||||||
find-garbage = "ls -l /nix/var/nix/gcroots/auto/ | sort | grep '/home/'";
|
find-garbage = "ls -l /nix/var/nix/gcroots/auto/ | sort | grep '/home/'";
|
||||||
vm = "vim";
|
vm = "vim";
|
||||||
|
|
|
@ -5,6 +5,6 @@ image=~/Downloads/$host.img.zst
|
||||||
|
|
||||||
cd ~/.nixos/
|
cd ~/.nixos/
|
||||||
|
|
||||||
nix build .#images.$host &&
|
nom build .#images.$host &&
|
||||||
cp result/sd-image/*.img.zst $image
|
cp result/sd-image/*.img.zst $image
|
||||||
chmod 644 $image
|
chmod 644 $image
|
||||||
|
|
|
@ -6,4 +6,4 @@ echo "experimental-features = nix-command flakes" > ~/.config/nix/nix.conf
|
||||||
nix-shell '<home-manager>' -A install
|
nix-shell '<home-manager>' -A install
|
||||||
rm ~/.config/nixpkgs/home.nix
|
rm ~/.config/nixpkgs/home.nix
|
||||||
ln -s $HOME/.nixos/flake.nix $HOME/.config/nixpkgs/flake.nix
|
ln -s $HOME/.nixos/flake.nix $HOME/.config/nixpkgs/flake.nix
|
||||||
home-manager switch
|
home-manager switch |& nom
|
||||||
|
|
|
@ -2,4 +2,4 @@
|
||||||
|
|
||||||
host=$1
|
host=$1
|
||||||
fqdn="nixos@nixos.2li.local"
|
fqdn="nixos@nixos.2li.local"
|
||||||
nixos-rebuild switch --use-remote-sudo --target-host $fqdn --impure --flake ".#$host"
|
nixos-rebuild switch --use-remote-sudo --target-host $fqdn --impure --flake ".#$host" |& nom
|
||||||
|
|
|
@ -32,10 +32,10 @@ do
|
||||||
fqdn="$host.2li.local"
|
fqdn="$host.2li.local"
|
||||||
if [ $reboot -eq 0 ]; then
|
if [ $reboot -eq 0 ]; then
|
||||||
echo $fqdn
|
echo $fqdn
|
||||||
nixos-rebuild switch -j auto --use-remote-sudo --target-host $fqdn --flake ".#$host"
|
nixos-rebuild switch -j auto --use-remote-sudo --target-host $fqdn --flake ".#$host" |& nom
|
||||||
else
|
else
|
||||||
echo "$fqdn with reboot"
|
echo "$fqdn with reboot"
|
||||||
nixos-rebuild boot -j auto --use-remote-sudo --target-host $fqdn --flake ".#$host" &&
|
nixos-rebuild boot -j auto --use-remote-sudo --target-host $fqdn --flake ".#$host" |& nom
|
||||||
ssh -i $rsa_key $fqdn 'sudo reboot'
|
ssh -i $rsa_key $fqdn 'sudo reboot'
|
||||||
fi
|
fi
|
||||||
echo
|
echo
|
||||||
|
|
|
@ -17,7 +17,7 @@ do
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
echo $host
|
echo $host
|
||||||
nixos-rebuild dry-build --flake .#${host}
|
nixos-rebuild dry-build --flake .#${host} |& nom
|
||||||
echo
|
echo
|
||||||
echo
|
echo
|
||||||
done
|
done
|
||||||
|
|
|
@ -5,4 +5,4 @@ export NIX_SSHOPTS="-t -i $rsa_key"
|
||||||
|
|
||||||
host=$1
|
host=$1
|
||||||
fqdn="$host.2li.local"
|
fqdn="$host.2li.local"
|
||||||
nixos-rebuild switch --use-remote-sudo --target-host $fqdn --flake ".#$host"
|
nixos-rebuild switch --use-remote-sudo --target-host $fqdn --flake ".#$host" |& nom
|
||||||
|
|
Loading…
Reference in New Issue