From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by passt.top (Postfix) with ESMTP id A4FFA5A02C7 for ; Mon, 13 May 2024 14:04:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1715601867; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=X4tVCrFIUEPBNcONcNHSIM0c8A8yTNCXVGucJDotIcc=; b=LlOPjfZSKVQNByiRvZKFliKgd6BfHQY54eGP/iiCtVnmAr74SvD1bWvR5RUuYlR16bfmNP PaxbfaByL7ethaZb+vRHFULv1JnMUj/F81BD0HLAvbdo9lOpawcdISkTQB884h2/iK+MKQ lZV+3GedVIQ5DeVrjHbogF+/WEPgic4= Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-625-DPOvQRDSMVybbA49jJ2Fhg-1; Mon, 13 May 2024 07:59:26 -0400 X-MC-Unique: DPOvQRDSMVybbA49jJ2Fhg-1 Received: by mail-wm1-f70.google.com with SMTP id 5b1f17b1804b1-42015260835so2847935e9.0 for ; Mon, 13 May 2024 04:59:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715601565; x=1716206365; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=X4tVCrFIUEPBNcONcNHSIM0c8A8yTNCXVGucJDotIcc=; b=Zlp4s2Y/N1lZyTtHKSK4mnim6Im5+gZHhdGDg5PmtHd7E3Gwjd18qhKpXycbCcluAQ FmQlWzrusbc43IbsOtHpvuUXwiWNcLxvg9g6Y0Igo+bLp3BmFu0mZe556NuPnOU1B3LW iZpzk2VnErGNaV4nN9hpjHve/LV6DIQq0Bkq4VeWwJUP5hIHkvv958a25JfJPDRNEgxZ YTX7e+nH02HQAOxufNFJlyR8mnvJEYo6NXwuSioGtKyur97vXreMc1SWtOCSKZ/guQs+ kJQNwFadm35ho7BO/7jeDWIjo3TGEEoGU6jE3YP3j2U5ArMNgVYHUEjEgUzu84LRqUO8 suhA== X-Forwarded-Encrypted: i=1; AJvYcCX6s3cIEkx8sS73qdZPlrTEzlsxDwl7/FjKBuqBF1vt4WT0EdC/VaBMbRb2wVlpB+cuCSoUgXddByo53pjJY90eOWKK X-Gm-Message-State: AOJu0YyEP+IuB8VH4gT1ft3+3S4nY2KPxl+qYW2cJn+WzBnKgX6kUgyg M3LvgULTPNyUgw0sHkAYNRENHs7W9oP+OcXICaDSPy1GZMjclw4mbNjvBnzzDEM6ri+gOlRZNiw lzl1T5DqpMvdLhpU2FVhP94KzrX2xME5vFoj2I3mAT8JAUqq5DA== X-Received: by 2002:a05:600c:2042:b0:41c:8123:f8a5 with SMTP id 5b1f17b1804b1-41feab40c4bmr70841435e9.23.1715601564889; Mon, 13 May 2024 04:59:24 -0700 (PDT) X-Google-Smtp-Source: AGHT+IERkDhhOFmUNbR6jX0sryZwfxUfSqhalyZej1dw4p0T5EzwdHEgWvC1W+fP4q7B+3PDxw5ozQ== X-Received: by 2002:a05:600c:2042:b0:41c:8123:f8a5 with SMTP id 5b1f17b1804b1-41feab40c4bmr70841325e9.23.1715601564517; Mon, 13 May 2024 04:59:24 -0700 (PDT) Received: from [192.168.188.25] ([80.243.52.133]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-41f87b2648fsm191140125e9.7.2024.05.13.04.59.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 13 May 2024 04:59:24 -0700 (PDT) Message-ID: Date: Mon, 13 May 2024 13:59:22 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Setting hostname while spawning pasta To: Danish Prakash , passt-dev@passt.top, Stefano Brivio References: From: Paul Holzinger In-Reply-To: X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Message-ID-Hash: L4NYD5EKEF7ADHQF4CJQ5XIOWJUSOPAE X-Message-ID-Hash: L4NYD5EKEF7ADHQF4CJQ5XIOWJUSOPAE X-MailFrom: pholzing@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Hi, On 09/05/2024 09:00, Danish Prakash wrote: > Hello > > I was having a discussion with a colleague of mine on how `pasta` when invoked > independently drops you in a new user and network namespace and how that causes > some folks to not realize what has happened especially because there's no cue > as to what transpired. This is not uncommon though, because a lot of > times, folks having > issues with pasta while running it with podman, tend to invoke pasta > directly to debug. > > I interacted with Stefano regarding this and he told me that pasta > already detaches > the UTS namespace and so in order to address this issue, I propose > that we set the hostname > as part of `pasta_spawn_cmd()`.Doing this would provide users with a > clear visual indication that > they are in a new user namespace (among other ns but that won't be > indicative here) and avoid > issues similar to the aforementioned. > > I'm looking to gather more opinions on how this change, if > implemented, would affect the > functionality. Looking forward to the discussion. > > Thank you > > danishpraka.sh > :wq > I don't have an issue with the hostname suggestion but it will not solve the problem of users not understanding that they are in a new user namespace. Maybe a more universal solution is to print a log line with a hint when no explicit command is given. Something like: "Spawning new shell in user+network namespace". That at least tells the user what pasta did and works even in cases where the prompt does not contain the hostname. Paul