From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id GI3wD9D4Z2Q5hAAASxT56A (envelope-from ) for ; Sat, 20 May 2023 00:31:44 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id EAQOEND4Z2SuQQAA9RJhRA (envelope-from ) for ; Sat, 20 May 2023 00:31:44 +0200 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 53D4BF1F6 for ; Sat, 20 May 2023 00:31:43 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q08cx-0006QZ-FO; Fri, 19 May 2023 18:31:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q08cw-0006QR-P1 for guix-devel@gnu.org; Fri, 19 May 2023 18:31:10 -0400 Received: from mx0.riseup.net ([198.252.153.6]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q08cu-0001mW-7a for guix-devel@gnu.org; Fri, 19 May 2023 18:31:10 -0400 Received: from fews02-sea.riseup.net (fews02-sea-pn.riseup.net [10.0.1.112]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mail.riseup.net", Issuer "R3" (not verified)) by mx0.riseup.net (Postfix) with ESMTPS id 4QNM4n0zzmz9t2P; Fri, 19 May 2023 22:31:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1684535465; bh=/GrahwEFf/xXU+h0QcWSRAAVoSFKlAvqnjHAXBNtNgc=; h=References:From:To:Cc:Subject:Date:In-reply-to:From; b=CkHZfHvdgzJgJz2DcA9beLB9VBXv/7n6SFIFjw9TUMdGyEA0B/qLtL+4CtVkbmcpT pFCalbAnq9O6b6RNm4WsPZYgiwWQ7wsx8FV6zNDcucFxvkGxdcqmERY5FySvdTylBX Ana65Z3Zxqgl0ONkOvvdeI9XDxA06OnGRN+Q0Zn4= X-Riseup-User-ID: AAACF75D1959359CD356FC6D12B7D9C47D3CB43CF624C75D57AC60D846449D43 Received: from [127.0.0.1] (localhost [127.0.0.1]) by fews02-sea.riseup.net (Postfix) with ESMTPSA id 4QNM4m1JhdzFqhy; Fri, 19 May 2023 22:31:03 +0000 (UTC) References: <87ilqch79l.fsf@remworks.net> <87mtde8mrr.fsf@gmail.com> <87h73m9z3f.fsf@remworks.net> <875ycb6n3w.fsf@remworks.net> <878rdk8gm9.fsf@remworks.net> From: Csepp To: Remco van 't Veer Cc: 55358@debbugs.gnu.org, Maxim Cournoyer , zimoun , guix-devel@gnu.org Subject: Re: bug#55358: docker containers stopped when doing guix install or guix shell Date: Sat, 20 May 2023 00:29:04 +0200 In-reply-to: <878rdk8gm9.fsf@remworks.net> Message-ID: <87fs7st0m3.fsf@riseup.net> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=198.252.153.6; envelope-from=raingloom@riseup.net; helo=mx0.riseup.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: guix-devel-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Seal: i=1; s=key1; d=yhetil.org; t=1684535504; a=rsa-sha256; cv=none; b=Hv/59b+BxQ34AWkySsvEJPWNrWcPsWxPs7Z1jiPe3NGbjtY3M6LAfxIDGvmEPh2MPogHAp viMRdjICaQWeCOJ+hIUR4K1DtHWCdFsy6UB1hh7mh5A33VQKUwaXk8K1Q17PLf7RBtJRAG cUEKJXOynxxn8JtHaFG1836dl4/Ti6CuwgjNZt8KVPEAXz0G+dgPButsQf4llVVUs0E1vi /dbGYTkwNGSxtqFpe/wca1jlX8Ktf2Mg5Rro0Y/TxbsdNcPwTO1+R4wLKtoF34ZuukBu0J TL4YaqmuLX421Ogr42V5MEncyUtkKDGagG7HEQ40lGyYB66fNhE9jqVyDYFQWA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=riseup.net header.s=squak header.b=CkHZfHvd; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1684535504; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=ltKMzyAlJh/tgMWDrW+6BEPg3Al3ytM9qA7/fYrQg5Q=; b=f406nQa4pFKAnO7H5sfjyNFsMHnTNcmFJ4zFeocmvII9JIxgH0GDezMMlMGuB6cgS9J6eo Hd19fmG1sNx9SpFz7IeNxc32ii2RdNpz018Dy16qy3eOmve0rMTKYAUP6Hz5a8QB7rw4yM Ty8RCfCcp5V084WN/AIMYe+UgUY/PNBtrplTG+OChQxBALACwUFgmVH0gB1aR4vN4GbqmI IWd0EWuJ78la5yLKHdDA/nov5T9RGXk4ul2iYovCZNMpLiqI+ngpEGmvq9K5kh3iVp6jFZ pMUI2wclKWlY4alI+wPD8Rv9GSuQaec3J0k8w7Sf3RQWlmcmnYp8KhlEXdI1CQ== X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=riseup.net header.s=squak header.b=CkHZfHvd; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.52 X-Spam-Score: -3.52 X-Migadu-Queue-Id: 53D4BF1F6 X-TUID: wyOKiIs2iaWW Remco van 't Veer writes: > Hi Maxim and Zimoun, > > 2023/02/09 13:26, Remco van 't Veer: > >> I think I know what is causing the issue. Both the "standard" mysql and >> postgres containers use user-id 999 to run the database service (this >> seems like a common practice because the redis container is configured >> similarly). That user-id is also configured as guixbuilder01 so I guess >> the guix daemon is killing those when processes when it finishes doing >> builds. > > I found a solution / workaround for this problem by using > "userns-remap". This feature allows the remapping of uids and guids to > different ranges. I tried it by hacking the required files into my > etc-directory and it works; guix no long kills my database containers. > > I'd like to add this feature to docker-service-type having a new > configuration option named enable-userns-remap? which introduces a new > user and group (both named dockremap) to do the remapping by adding some > configurable number to the uids and guids of the running container. In > /etc/subuid and /etc/subgid it would look like: > > dockremap:100000:65536 > > See https://docs.docker.com/engine/security/userns-remap/ for > documentation about this. > > WDYT? > > Cheers, > Remco The rootless podman example that was shared a few months ago could be relevant to this, since that also adds a subuid/subgid mapping.