From patchwork Wed Aug 7 12:43:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Jakob L. Kreuze" X-Patchwork-Id: 14885 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 6266F17274; Wed, 7 Aug 2019 13:47:25 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 2E17F17252 for ; Wed, 7 Aug 2019 13:47:25 +0100 (BST) Received: from localhost ([::1]:40662 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hvLLg-0000y4-SY for patchwork@mira.cbaines.net; Wed, 07 Aug 2019 08:47:24 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48611) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hvLLM-0000Ll-57 for guix-patches@gnu.org; Wed, 07 Aug 2019 08:47:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hvLLK-0004uW-7M for guix-patches@gnu.org; Wed, 07 Aug 2019 08:47:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:57577) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hvLLJ-0004uK-V9 for guix-patches@gnu.org; Wed, 07 Aug 2019 08:47:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hvLLJ-0000Nh-SJ for guix-patches@gnu.org; Wed, 07 Aug 2019 08:47:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#36954] [PATCH] deploy: Use all machine modules when loading deployment Resent-From: zerodaysfordays@sdf.lonestar.org (Jakob L. Kreuze) Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 07 Aug 2019 12:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 36954 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 36954@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15651820061442 (code B ref -1); Wed, 07 Aug 2019 12:47:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Aug 2019 12:46:46 +0000 Received: from localhost ([127.0.0.1]:38165 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hvLL4-0000NB-3U for submit@debbugs.gnu.org; Wed, 07 Aug 2019 08:46:46 -0400 Received: from lists.gnu.org ([209.51.188.17]:51899) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hvLL0-0000N1-MB for submit@debbugs.gnu.org; Wed, 07 Aug 2019 08:46:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48505) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hvLKz-0008Fi-KD for guix-patches@gnu.org; Wed, 07 Aug 2019 08:46:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hvLKy-0004aC-Ml for guix-patches@gnu.org; Wed, 07 Aug 2019 08:46:41 -0400 Received: from mx.sdf.org ([205.166.94.20]:65213) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hvLKy-0004Zn-Eq for guix-patches@gnu.org; Wed, 07 Aug 2019 08:46:40 -0400 Received: from Epsilon (pool-173-76-53-40.bstnma.fios.verizon.net [173.76.53.40]) (authenticated (0 bits)) by mx.sdf.org (8.15.2/8.14.5) with ESMTPSA id x77Ckc3J000874 (using TLSv1.2 with cipher AES256-GCM-SHA384 (256 bits) verified NO) for ; Wed, 7 Aug 2019 12:46:39 GMT From: zerodaysfordays@sdf.lonestar.org (Jakob L. Kreuze) Date: Wed, 07 Aug 2019 08:43:27 -0400 Message-ID: <87mugl4040.fsf@sdf.lonestar.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * guix/scripts/deploy.scm (load-source-file): Enumerate and include all submodules of (gnu machine) when loading the provided deployment specification. --- guix/scripts/deploy.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/guix/scripts/deploy.scm b/guix/scripts/deploy.scm index bc1d93a93a..6a67985c8b 100644 --- a/guix/scripts/deploy.scm +++ b/guix/scripts/deploy.scm @@ -19,6 +19,7 @@ (define-module (guix scripts deploy) #:use-module (gnu machine) + #:use-module (guix discovery) #:use-module (guix scripts) #:use-module (guix scripts build) #:use-module (guix store) @@ -73,7 +74,10 @@ Perform the deployment specified by FILE.\n")) (define (load-source-file file) "Load FILE as a user module." - (let ((module (make-user-module '((gnu) (gnu machine) (gnu machine ssh))))) + (let* ((guix-path (dirname (search-path %load-path "guix.scm"))) + (environment-modules (scheme-modules* guix-path "gnu/machine")) + (module (make-user-module (append '((gnu) (gnu machine)) + environment-modules)))) (load* file module))) (define (guix-deploy . args)