forked from clan/clan-core
Compare commits
2 Commits
main
...
a-kenji-cl
Author | SHA1 | Date | |
---|---|---|---|
c7c400f51f | |||
ea6bd8f41d |
@ -38,6 +38,8 @@ def install_nixos(
|
|||||||
|
|
||||||
cmd = [
|
cmd = [
|
||||||
"nixos-anywhere",
|
"nixos-anywhere",
|
||||||
|
"--debug",
|
||||||
|
"--copy-password",
|
||||||
"--flake",
|
"--flake",
|
||||||
f"{machine.flake}#{machine.name}",
|
f"{machine.flake}#{machine.name}",
|
||||||
"--no-reboot",
|
"--no-reboot",
|
||||||
@ -54,7 +56,8 @@ def install_nixos(
|
|||||||
|
|
||||||
run(
|
run(
|
||||||
nix_shell(
|
nix_shell(
|
||||||
["nixpkgs#nixos-anywhere"],
|
# ["nixpkgs#sshpass", "/home/kenji/git/nix-projects/nixos-anywhere"],
|
||||||
|
["nixpkgs#sshpass", "nixpkgs#nixos-anywhere"],
|
||||||
cmd,
|
cmd,
|
||||||
),
|
),
|
||||||
log=Log.BOTH,
|
log=Log.BOTH,
|
||||||
@ -117,6 +120,18 @@ def register_install_parser(parser: argparse.ArgumentParser) -> None:
|
|||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
"target_host",
|
"target_host",
|
||||||
type=str,
|
type=str,
|
||||||
|
nargs="?",
|
||||||
help="ssh address to install to in the form of user@host:2222",
|
help="ssh address to install to in the form of user@host:2222",
|
||||||
)
|
)
|
||||||
|
group = parser.add_mutually_exclusive_group(required=False)
|
||||||
|
group.add_argument(
|
||||||
|
"-j",
|
||||||
|
"--json",
|
||||||
|
help="specify the json file for ssh data (generated by starting the clan installer)",
|
||||||
|
)
|
||||||
|
group.add_argument(
|
||||||
|
"-P",
|
||||||
|
"--png",
|
||||||
|
help="specify the json file for ssh data as the qrcode image (generated by starting the clan installer)",
|
||||||
|
)
|
||||||
parser.set_defaults(func=install_command)
|
parser.set_defaults(func=install_command)
|
||||||
|
Loading…
Reference in New Issue
Block a user