Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flake archive SSH usage with ControlMaster and ControlPath hangs forever #10645

Open
nim65s opened this issue May 4, 2024 · 1 comment
Open
Labels

Comments

@nim65s
Copy link

nim65s commented May 4, 2024

Describe the bug

Hi,

Flake archive SSH usage with ControlMaster and ControlPath hangs forever.

This is similar to #8329, but on flake archive and with ControlPath.

Steps To Reproduce

With a ~/.ssh/config containing:

ControlMaster yes
ControlPath ~/.ssh/master-%r@%n:%p

Run eg. nix --extra-experimental-features 'nix-command flakes' flake archive --to ssh://root@my-remote-nixos --json .

It hangs forever, and don't upload source to destination.

Expected behavior

flake source should be uploaded to ssh store on my-remote-nixos

nix-env --version output

tried both on nix (Nix) 2.18.2 & nix (Nix) 2.23.0pre20240503_00ca2b0

Additional context

Changing ~/.ssh/config by either setting no to ControlMaster or removing ControlPathfix the behaviour.

A workaround is to use NIX_SSHOPTS="-o ControlMaster=no"

This command is used by clan cli.

Priorities

Add 👍 to issues you find important.

@nim65s nim65s added the bug label May 4, 2024
@nim65s
Copy link
Author

nim65s commented May 4, 2024

A wild guess is that there is an inconsistency between the socket path provided by ControlPath and the socket path provided at

state->socketPath = (Path) *state->tmpDir + "/ssh.sock";

Edit: setting both to /tmp/ssh.sock doesn't fix it, so the guess was probably wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant