diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2019-10-10 12:54:37 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2019-10-10 12:54:37 +0200 |
commit | e99bb9121787ae30a1872f63b326ce5c130ec7ef (patch) | |
tree | ecdd2b7ba575b0848d2770f8e74b40646f512c71 /src/nix-daemon/nix-daemon.cc | |
parent | d343c03edb8d4d2be7aca4f1a377544b3889b8b3 (diff) | |
parent | c3aaf3b8da1a925c569389f13a861816a781a3c8 (diff) |
Merge remote-tracking branch 'origin/master' into flakes
Diffstat (limited to 'src/nix-daemon/nix-daemon.cc')
-rw-r--r-- | src/nix-daemon/nix-daemon.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/nix-daemon/nix-daemon.cc b/src/nix-daemon/nix-daemon.cc index e88aaf636..cd18489b0 100644 --- a/src/nix-daemon/nix-daemon.cc +++ b/src/nix-daemon/nix-daemon.cc @@ -742,7 +742,8 @@ static void performOp(TunnelLogger * logger, ref<Store> store, } -static void processConnection(bool trusted) +static void processConnection(bool trusted, + const std::string & userName, uid_t userId) { MonitorFdHup monitor(from.fd); @@ -793,6 +794,8 @@ static void processConnection(bool trusted) params["path-info-cache-size"] = "0"; auto store = openStore(settings.storeUri, params); + store->createUser(userName, userId); + tunnelLogger->stopWork(); to.flush(); @@ -1053,7 +1056,7 @@ static void daemonLoop(char * * argv) /* Handle the connection. */ from.fd = remote.get(); to.fd = remote.get(); - processConnection(trusted); + processConnection(trusted, user, peer.uid); exit(0); }, options); @@ -1133,7 +1136,7 @@ static int _main(int argc, char * * argv) } } } else { - processConnection(true); + processConnection(true, "root", 0); } } else { daemonLoop(argv); |