Skip to content

sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper #312

@Henry-Hiles

Description

@Henry-Hiles

Whenever I nh os switch with a remote server, I get the error:

sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
sudo: a password is required

Command ran with -v --no-nom:

TRACE nh::logging:86: Logging OK
DEBUG nh:28: Main {
    verbose: true,
    command: Os(
        OsArgs {
            subcommand: Switch(
                OsRebuildArgs {
                    common: CommonRebuildArgs {
                        dry: false,
                        ask: false,
                        installable: Flake {
                            reference: "/home/quadradical/.config/nixos",
                            attribute: [],
                        },
                        no_nom: true,
                        out_link: None,
                    },
                    update_args: UpdateArgs {
                        update: false,
                        update_input: None,
                    },
                    hostname: Some(
                        "quadraticserver",
                    ),
                    specialisation: None,
                    no_specialisation: false,
                    extra_args: [],
                    bypass_root_check: false,
                    target_host: Some(
                        "192.168.0.132",
                    ),
                    build_host: None,
                },
            ),
        },
    ),
}
DEBUG nh:29: NH_VERSION=4.1.0 NH_REV=Some("1ea27e7")
DEBUG nh::commands:160: cmd=Exec { nix --version }
DEBUG nh::commands:160: cmd=Exec { nix --version }
DEBUG nh::commands:160: cmd=Exec { nix --version }
DEBUG nh::commands:160: cmd=Exec { nix --version }
DEBUG nh::checks:85: Required Nix features: nix-command, flakes, repl-flake
DEBUG nh::commands:160: cmd=Exec { nix config show experimental-features }
DEBUG nh::checks:91: Enabled Nix features: nix-command, repl-flake, flakes
DEBUG nh::commands:160: cmd=Exec { nix config show experimental-features }
DEBUG nh::checks:111: All required Nix features are enabled
DEBUG nh::nixos:125: out_path=("/tmp/nh-osUkFNX5/result", TempDir { path: "/tmp/nh-osUkFNX5" })
> Building NixOS configuration
DEBUG nh::commands:256: cmd=Exec { nix build '/home/quadradical/.config/nixos#nixosConfigurations.quadraticserver.config.system.build.toplevel' --out-link /tmp/nh-osUkFNX5/result }
DEBUG nh::nixos:173: target_specialisation: None
DEBUG nh::nixos:180: Output path: /tmp/nh-osUkFNX5/result
DEBUG nh::nixos:181: Target profile path: /tmp/nh-osUkFNX5/result
DEBUG nh::nixos:182: Target profile exists: true
DEBUG nh::nixos:214: Not running nvd as the target hostname is different from the system hostname.
> Copying configuration to target
DEBUG nh::commands:137: cmd=Exec { nix copy --to 'ssh://192.168.0.132' /tmp/nh-osUkFNX5/result }
> Activating configuration
DEBUG nh::commands:137: cmd=Exec { ssh -T 192.168.0.132 }
sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
sudo: a password is required
DEBUG nh::commands:137: cmd=Exec { ssh -T 192.168.0.132 }
sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
sudo: a password is required
> Adding configuration to bootloader
DEBUG nh::commands:137: cmd=Exec { ssh -T 192.168.0.132 }
sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
sudo: a password is required
DEBUG nh::nixos:286: Completed operation with output path: "/tmp/nh-osUkFNX5/result"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions