From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id YFW8C4mCz14mGAAA0tVLHw (envelope-from ) for ; Thu, 28 May 2020 09:21:13 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id QD+hB4mCz16gdwAAbx9fmQ (envelope-from ) for ; Thu, 28 May 2020 09:21:13 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 42BAD940C04 for ; Thu, 28 May 2020 09:21:12 +0000 (UTC) Received: from localhost ([::1]:44426 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jeEir-0003KV-Dd for larch@yhetil.org; Thu, 28 May 2020 05:21:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35236) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jeEik-0003Ja-Fv for bug-guix@gnu.org; Thu, 28 May 2020 05:21:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:39438) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jeEik-0004QK-7T for bug-guix@gnu.org; Thu, 28 May 2020 05:21:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jeEik-00070T-3w for bug-guix@gnu.org; Thu, 28 May 2020 05:21:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#41575: Container with openssh-service requires sshd user on the host Resent-From: Edouard Klein Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 28 May 2020 09:21:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 41575 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 41575@debbugs.gnu.org X-Debbugs-Original-To: bug-guix@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.159065765626906 (code B ref -1); Thu, 28 May 2020 09:21:01 +0000 Received: (at submit) by debbugs.gnu.org; 28 May 2020 09:20:56 +0000 Received: from localhost ([127.0.0.1]:50984 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jeEid-0006zu-J9 for submit@debbugs.gnu.org; Thu, 28 May 2020 05:20:55 -0400 Received: from lists.gnu.org ([209.51.188.17]:46732) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jeEic-0006zm-Ey for submit@debbugs.gnu.org; Thu, 28 May 2020 05:20:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35218) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jeEic-0003Fn-9Q for bug-guix@gnu.org; Thu, 28 May 2020 05:20:54 -0400 Received: from sender4-op-o11.zoho.com ([136.143.188.11]:17144) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1jeEia-0004NL-D7 for bug-guix@gnu.org; Thu, 28 May 2020 05:20:53 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1590657647; cv=none; d=zohomail.com; s=zohoarc; b=ZREpzXgiRkEaCrNVp0DYBA37uoKHFPCK/01VFlYPxhK0X7GsGoBwZcUgrXudK1mNe0yXS5dOla2M2lV8hwATIfmE2wSFBWym/E3JJaJlr2oujJ2wco9edhky78zaC6LECeSEzXy5EeIjKHm9cnHUeKB9tpwo/tFLTDL4fqdgBiM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1590657647; h=Content-Type:Content-Transfer-Encoding:Date:From:MIME-Version:Message-ID:Subject:To; bh=+W+JdqwJiJ08FuqR32WeQBMzViYIWMIGk1+8crQcnkE=; b=mpMDnL2k6kECpKnxtiW0mnXoWMuqP7QUOKPxs6wiSQNX+M3fj/pYP3+/+rnkYErzmjTLj5yaorrmEGChdxlcwDlAnSIc/CgSM+wTPBL+rOXsyL/10R+LRX00vUPL4eJpmAIT5Nx+tlivpm3ioF/4jNGFDRsKfCkSbfWeg25LAeo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=beaver-labs.com; spf=pass smtp.mailfrom=edk@beaver-labs.com; dmarc=pass header.from= header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1590657647; s=zoho; d=beaver-labs.com; i=edk@beaver-labs.com; h=From:To:Subject:Message-ID:Date:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=+W+JdqwJiJ08FuqR32WeQBMzViYIWMIGk1+8crQcnkE=; b=G0mG3Veg0k6A4717M+hkDhmAcMmEBOw4iVNyDMHs8BiboKqFum8cO5hEa2yt7S2W fnxNlwZp/aHsCoSxIwkexCWap7tA6nmZgfEX+xqt1JHgbuZSe0uwu6MJLZ1P5+8koLJ Klk6X6lnPKDTBg5mZ6KKZnq9jEjAx4GvTaTH4yNg= Received: from alice.lan (lfbn-idf1-1-1299-119.w90-79.abo.wanadoo.fr [90.79.23.119]) by mx.zohomail.com with SMTPS id 1590657645301491.4925981819242; Thu, 28 May 2020 02:20:45 -0700 (PDT) User-agent: mu4e 1.4.6; emacs 26.3 From: Edouard Klein Message-ID: <87mu5s2z6u.fsf@alice.lan> Date: Thu, 28 May 2020 11:20:25 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-ZohoMailClient: External Received-SPF: pass client-ip=136.143.188.11; envelope-from=edk@beaver-labs.com; helo=sender4-op-o11.zoho.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/28 05:20:49 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-Spam-Score: -1.4 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -2.4 (--) X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=beaver-labs.com header.s=zoho header.b=G0mG3Veg; dmarc=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Spam-Score: 1.99 X-TUID: IWk1u9eAOWxd Dear guix, This is a funny one. Consider this minimal operating system definition: ----------- (use-modules (gnu)) (use-service-modules ssh) (operating-system (host-name "MinimalSSH") (timezone "Europe/Paris") (bootloader (bootloader-configuration (bootloader grub-bootloader))) (file-systems %base-file-systems) (services (append (list=20 (service openssh-service-type (openssh-configuration (port-number 2222)))) %base-services))) ----------- If I try to create a container (with network of course): guix system container ~/src/gendscraper/minimal_openssh.scm --network And run the container sudo /gnu/store/6dvy8acvzkzfba8hjf4nfc3ps2rwns5j-run-container I get the error I pasted at the end of this email. If, however, I create a sshd user on the host, it runs without a hitch and I can talk to the ssh server on localhost:2222 Funny things: - It will run if I remove the --network (but then I can't connect to the ssh server, of course) - It will run if I userdel sshd, until I reboot The ncsd daemon is running on the host. My goal with guix containers is to avoid having to make any configuration on the foreign host (apart from installing guix), is this normal that the sshd user has to be present for the container to run the ssh daemon ? If it is, how can I know in advance which service requires which configuration on the host ? Thanks in advance for any help, please do not hesitate to ask for more information about my config (Arch) if need be. Cheers, Edouard. --------------- sudo /gnu/store/6dvy8acvzkzfba8hjf4nfc3ps2rwns5j-run-container guile: warning: failed to install locale system container is running as PID 3934 Run 'sudo guix container exec 3934 /run/current-system/profile/bin/bash --l= ogin' or run 'sudo nsenter -a -t 3934' to get a shell into it. making '/gnu/store/ml63vj43bv4lrmwdvpm6jqyya24z6zkr-system' the current sys= tem... setting up setuid programs in '/run/setuid-programs'... populating /etc from /gnu/store/a4d90ypz1xylh97ff2b4ysj33hwnmfva-etc... Backtrace: 12 (primitive-load "/gnu/store/6dvy8acvzkzfba8hjf4nfc3ps2r=E2=80= =A6") In gnu/build/linux-container.scm: 297:8 11 (call-with-temporary-directory #) 325:16 10 (_ _) 62:6 9 (call-with-clean-exit _) In unknown file: 8 (primitive-load "/gnu/store/ml63vj43bv4lrmwdvpm6jqyya24=E2=80= =A6") In ice-9/eval.scm: 619:8 7 (_ #f) In unknown file: 6 (primitive-load "/gnu/store/zdqjch5xknlhp6dvnl6vdrlfnbm=E2=80= =A6") In srfi/srfi-1.scm: 640:9 5 (for-each # _) In unknown file: 4 (primitive-load "/gnu/store/y19c6kipzqigz15v4hvy53x2vaz=E2=80= =A6") In gnu/build/activation.scm: 145:2 3 (activate-users+groups _ _) In srfi/srfi-1.scm: 640:9 2 (for-each # _) In gnu/build/activation.scm: 115:16 1 (make-home-directory #< name: "sshd" pass=E2=80= =A6>) In unknown file: 0 (getpw "sshd") ERROR: In procedure getpw: In procedure getpw: entry not found