Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 94AEEF4ED for ; Tue, 1 Apr 2025 21:17:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743542231; cv=none; b=S4WALsDRRCgRXeAZYCKu9Nb0ZZuSYUt8xt9PlMHMWAQxnsTvIOP30D5IfO7JVETXGu4wad3Sq7Kb7FXnl6lnx4aOtuAm9L9iwEVZZ0N61aPC0etsnzwzt0kMztQHa9o4ceUapo7l60/XhIdUeDuIDztbMi0WVa9Ra51bHnBC8s8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743542231; c=relaxed/simple; bh=wBPBztRecGZXaBPUm7eS9nSmNu3GcuR5OGUHvxBiBUI=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=djigcY/HPAbpx9TRI99ytok8XQG3PJSeLCUOpw0eRxcagE0eA6SoNELqTMjKBEpQi6bnDLCxsTXWefb/UYBB5dpYSDAA4rOgy55sFtJIr9j9ixgMrZpuME0+KS/FRXrEu0LoUE8duSfbMPAjs9zYHFKKw4v1UrmMiCBNG0s72l0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=q0Z1x/o4; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="q0Z1x/o4" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E5F8DC4CEE4; Tue, 1 Apr 2025 21:17:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1743542231; bh=wBPBztRecGZXaBPUm7eS9nSmNu3GcuR5OGUHvxBiBUI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=q0Z1x/o44x4wsC4gZnc8ziUSwe/dRlQ8n3tbAurBBEYbKqwJmX3UvRKB9+ZTMEIOG nsyNQBVGSjoxh9OrcAi7f4hCXmwSSZfIhUxW22kZEd7ux/boMCpTBb3Daad/ELk2bW DTH1xiPsTiTbbPe6nkH6nUSmOVJwsIZrti5MPbYg+3q2Ua6GFWzOXR1Q9IGXX/mmwN GD5tQ88Sgf31PVwP+yuSb9drFhI33OdiKrZ55mCiDTWMcFSSYqeYtu1IToKl3IqaSy JLCnXYW/cA/Nb+0zerfooMo4JSOD+d3nTYwapAlxY04DdzgULwmme9wLfL7s9QoCe/ vJGt+wgcmgjLA== Date: Tue, 1 Apr 2025 14:17:09 -0700 From: Luis Chamberlain To: Daniel Gomez Cc: kdevops@lists.linux.dev, Joel Granados , Andreas Hindborg Subject: Re: [RFC] bringup: add semantics to start NixOS support Message-ID: References: <20250331100928.5284-1-mcgrof@kernel.org> Precedence: bulk X-Mailing-List: kdevops@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Tue, Apr 01, 2025 at 01:30:30PM +0200, Daniel Gomez wrote: > On Mon, Mar 31, 2025 at 03:09:28AM +0100, Luis Chamberlain wrote: > > Tons still left to do... but hey, at least we get to trim clutter out > > and can aim for a simple setup. TODO: > > > > - playbooks/bringup_nixos.yml > > - playbooks/update_ssh_config_nixos.yml > > > > We can probably just trim nixos.nix.j2 so to at least bring up > > a libvirt guest first, and then the second step is to use process > > a set of target nodes under a simple workflow. > > > > So the only thing here this does is show how we need to first > > add tons of "support" bools and make terraform and guestfs to select > > them. That should probably just be its own patch before all this. > > > > Then the makefile shows the bare bones bringup we need. But we can > > probably simplify that more. > > > > Signed-off-by: Luis Chamberlain > > I have a WIP branch with some cleanup needed for this: > > https://github.com/dkruces/kdevops/commits/nixos/ OK that and this patch can likely get us going somewhere fast. > * kdevops: add nixos support > This simply makes kdevops runnable in NixOS by > chaning all the shebangs in scripts/. > > * Makefile.kdevops: drop ansible_python_intepreter > Once ansible cfg series are merged, I think we an get rid of the python > interperter in the ansible calls and configure that in Kconfig -> ansible.cfg. > > * shell.nix > Just to launch a Nix shell with all kdevops dependencies. > > * libvirt_user: add nixos support > Generates a kdevops/ in your Nix configuration/ folder. Output: > https://github.com/dkruces/nixos-config/tree/main/kdevops > > My initial idea was to generate NixOS configuration with Ansible [1]. If folks don't want to use libvirt they can just a config yaml entry describing their qemu junk, and Kconfig should be able then to read that in and populate pool crap and all that. Do nixos users with virtualization who are on debian use session URI or system URI? I ask as system URI crap requires privileges, which is why we do tons of hoops with sudo for system URI. Fedora based distros use session URI by default Debian based distros use system URI by default What do we want to assume for nix os users? > But Joel > tried something different with flakes I think. Adding him to get more feeback > on it. > > One thing he found was the need of a hack to be able to launch virt-builder [2]: Hrm, so the use case was to use virt-builder with nix? Is that the nixy way to deal with things? Luis