예제 #1
0
    def deploy(h: DeployHost) -> None:
        h.run_local(
            f"rsync {' --exclude '.join([''] + RSYNC_EXCLUDES)} -vaF --delete -e ssh . {h.user}@{h.host}:/etc/nixos"
        )

        # FIXME: build03 has itself as a builder and deadlocks building packages.
        h.run(
            f"nixos-rebuild switch --builders '' --option accept-flake-config true"
        )
예제 #2
0
    def deploy(h: DeployHost) -> None:
        h.run_local(
            f"rsync --exclude=`git ls-files --exclude-standard -oi --directory` --exclude='.git/' -vaF --delete -e ssh . {h.user}@{h.host}:/etc/nixos",
        )

        flake_path = "/etc/nixos"
        flake_attr = h.meta.get("flake_attr")
        if flake_attr:
            flake_path += "#" + flake_attr
        target_host = h.meta.get("target_host", "localhost")
        h.run(
            f"nixos-rebuild switch --build-host localhost --target-host {target_host} --flake {flake_path}"
        )
예제 #3
0
    def deploy(h: DeployHost) -> None:
        h.run_local(
            f"rsync {' --exclude '.join([''] + RSYNC_EXCLUDES)} -vaF --delete -e ssh . {h.user}@{h.host}:/etc/nixos"
        )

        flake_path = "/etc/nixos"
        flake_attr = h.meta.get("flake_attr")
        if flake_attr:
            flake_path += "#" + flake_attr
        target_host = h.meta.get("target_host", "localhost")
        h.run(
            f"nixos-rebuild switch --build-host localhost --target-host {target_host} --flake {flake_path}"
        )
예제 #4
0
 def doc_tum(h: DeployHost) -> None:
     h.run_local(f"../../get-lldp-neighbors.sh {h.host}")
예제 #5
0
 def doc_host(h: DeployHost) -> None:
     h.run_local(f"../generate-host-info.sh {h.host}")