# SSH works, but remote building says it can't connect

**URL:** https://discourse.nixos.org/t/ssh-works-but-remote-building-says-it-cant-connect/67023
**Category:** Help
**Created:** [July 21, 2025, 6:11pm UTC](https://discourse.nixos.org/t/ssh-works-but-remote-building-says-it-cant-connect/67023 "2025-07-21T18:11:11Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![waffle8946](https://discourse.nixos.org/user_avatar/discourse.nixos.org/waffle8946/32/27221_2.png) [@waffle8946](https://discourse.nixos.org/u/waffle8946)
#### Post date: [November 15, 2025, 12:29pm UTC](https://discourse.nixos.org/t/ssh-works-but-remote-building-says-it-cant-connect/67023/3 "2025-11-15T12:29:15Z")

</div>

Adding users to `trusted-users` is a bad idea, as they can modify things like substituters.

[https://nix.dev/manual/nix/2.32/command-ref/conf-file.html#conf-trusted-users](https://nix.dev/manual/nix/2.32/command-ref/conf-file.html#conf-trusted-users)

> > **Warning**
> 
> Adding a user to `trusted-users` is essentially equivalent to giving that user root access to the system. For example, the user can access or replace store path contents that are critical for system security.

Use [`allowed-users`](https://nix.dev/manual/nix/2.32/command-ref/conf-file.html#conf-allowed-users) instead.

---

_[View the full topic](https://discourse.nixos.org/t/ssh-works-but-remote-building-says-it-cant-connect/67023)._
