From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 92E8D13832E for ; Mon, 22 Aug 2016 17:32:42 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2AF5A21C201; Mon, 22 Aug 2016 17:32:37 +0000 (UTC) Received: from mail-qk0-f195.google.com (mail-qk0-f195.google.com [209.85.220.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0987E21C1F8 for ; Mon, 22 Aug 2016 17:32:36 +0000 (UTC) Received: by mail-qk0-f195.google.com with SMTP id v123so8812435qkh.3 for ; Mon, 22 Aug 2016 10:32:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to; bh=+JQQeylYrM6nyp/nWyxDclcRY8yfKpKBDpoAvPbHfrs=; b=CEHjA2IgnxOwTod4yvrUwwXZCNtqd5yR+b6JZYJLbTdQsC8n0ykMDWwANbR63OzcRa VUvuUpX6hKDKJ3dkOtczSgTLTHt0J4xdzpcT7E6QhdKYsHwOMzKAdcU6BzeVIdQHVfZf km5qS654LmGozm0h+fviLAu6KBJavhJ/gf8YsdvAWMigQFhiU2VhpJrskr/GNSLmD6jJ LTQ7OD9ZP13gCPKfmQmJ0ma+Zn9et1Wa/ru2nV5kJ9amvlzTtubkl7Dul8hz5CuY85rx CrGaLuqmQRI/ahC5wTspu7I6Nhao9/KEcw4N7eJb05pv9roMs0Rvnfu7hAbObVYgpBqj NTpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to; bh=+JQQeylYrM6nyp/nWyxDclcRY8yfKpKBDpoAvPbHfrs=; b=IczJ+hKdIgBcbbtCl2X7WYvGb8dutEX9vyeIs73/RwUZ6FLdKH6XiDfdIyvFcH8jJ8 mRCAnmrupLcNmYecjAMYPr+mtEqvcCXeg/+l75BABLOHSMxmnh8S/ZIttwPy8dN834Kh HvyuBkJ/BYwfArzKOAUe0u8qhlthh6GuhZjLcWlYkbwt/71BieZfh0/Y8a5oTUkBXTiT BSBjppzaheaR2ShaAWaDDNyOrcP9IIU3UuFpdTETRNw+9Rg36/n35GD0YGQo4Gdbg/OV 3dRlobSCC6gCi+hOnsvtTLQ5IEQVLqC3Y9zQDlzF0l6XbaPYzfz+Ij2ZicP7o9JZmJEt mdvw== X-Gm-Message-State: AEkoousPuHnyoraDZ3Sg9u9ZnmhywTeLwHlLI57Ly1mK2vDVMbrwBm8v61PYMgOua/pTqxyzysUu9Mnl4fBptg== X-Received: by 10.55.27.106 with SMTP id b103mr24413727qkb.224.1471887155070; Mon, 22 Aug 2016 10:32:35 -0700 (PDT) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 Sender: freemanrich@gmail.com Received: by 10.140.40.36 with HTTP; Mon, 22 Aug 2016 10:32:34 -0700 (PDT) In-Reply-To: <20160822170342.GA16554@whubbs1.gaikai.biz> References: <20160822155808.GA16219@whubbs1.gaikai.biz> <57BB2439.4050408@iee.org> <20160822170342.GA16554@whubbs1.gaikai.biz> From: Rich Freeman Date: Mon, 22 Aug 2016 13:32:34 -0400 X-Google-Sender-Auth: 6rD3YI8aq0htJr68OuGxRNmdpnc Message-ID: Subject: Re: [gentoo-dev] rfc: /etc/hostname on gentoo To: gentoo-dev Content-Type: text/plain; charset=UTF-8 X-Archives-Salt: c3969d22-580e-4030-9b29-91d0464b39a3 X-Archives-Hash: 5401d9cff9ba0cde6e63f0f746be2d88 On Mon, Aug 22, 2016 at 1:03 PM, William Hubbs wrote: > > I'm not sure about putting this in /run for a couple of reasons: > > The contents of this file is a setting, like /etc/conf.d/hostname, which > will be set by the user. There is no reason a script can't populate /run with the right thing. For example, with systemd you can set up a static networking config with a static DNS, and it will populate a resolv.conf in /run with whatever it parsed out of your networkd configuration. Or you can tell it to use dhcp in which case it populates /run with whatever the dhcp server gives it. The idea is that only one tool has to worry about where to get the right network settings from, and everything else can just read them in whatever format they prefer from wherever it is preferred. However, it isn't the only way to accomplish this goal. You could just keep writing to /etc. That does break in situations where you want /etc to be read-only, etc. > > The other reason is, I don't know enough about containers to know if > they will have a separate /run from the host. > Typically containers will have their own /run. Containers were one of the big reasons to not store hostnames in /etc, since then you can share a single image across many containers, with a static /etc, and the dynamic stuff all goes in /run. Containers are also one of the reasons for ditching /etc/mtab. -- Rich