GNU bug report logs - #30806
[PATCH] Add terraform and terraform-provider-libvirt

Previous Next

Package: guix-patches;

Reported by: Christopher Baines <mail <at> cbaines.net>

Date: Tue, 13 Mar 2018 20:26:01 UTC

Severity: normal

Tags: moreinfo, patch

Merged with 44721

Done: Sharlatan Hellseher <sharlatanus <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 30806 <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: 30806 <at> debbugs.gnu.org
Subject: [PATCH 2/2] gnu: Add terraform-provider-libvirt.
Date: Tue, 13 Mar 2018 20:30:08 +0000
* gnu/packages/terraform.scm (terraform-provider-libvirt): New variable.
---
 gnu/packages/terraform.scm | 48 +++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 47 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/terraform.scm b/gnu/packages/terraform.scm
index 277d19aed..e81ada45d 100644
--- a/gnu/packages/terraform.scm
+++ b/gnu/packages/terraform.scm
@@ -21,7 +21,11 @@
   #:use-module (guix packages)
   #:use-module (guix download)
   #:use-module (guix git-download)
-  #:use-module (guix build-system go))
+  #:use-module (guix build-system go)
+  #:use-module (gnu packages golang)
+  #:use-module (gnu packages cdrom)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages virtualization))
 
 (define-public terraform
   (package
@@ -58,3 +62,45 @@ apply changes to the described resources.
 Terraform uses plugins that provide intergrations to different providers.")
     (home-page "https://www.terraform.io/")
     (license license:mpl2.0)))
+
+(define-public terraform-provider-libvirt
+  (package
+    (name "terraform-provider-libvirt")
+    (version "0.3")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/dmacvicar/terraform-provider-libvirt")
+                    (commit (string-append "v" version))))
+              (sha256
+               (base32
+                "004gxy55p5cf39f2zpah0i2zhvs4x6ixnxy8z9v7314604ggpkna"))))
+    (build-system go-build-system)
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("libvirt" ,libvirt)
+       ("cdrtools" ,cdrtools)))
+    (arguments
+     '(#:import-path "github.com/dmacvicar/terraform-provider-libvirt"
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-mkisofs
+           (lambda* (#:key inputs #:allow-other-keys)
+             (substitute*
+                 "src/github.com/dmacvicar/terraform-provider-libvirt/libvirt/cloudinit_def.go"
+               (("mkisofs")
+                (string-append (assoc-ref inputs "cdrtools")
+                               "/bin/mkisofs")))))
+         ;; This should be redundant once the vendor directory is removed from
+         ;; this package
+         (add-before 'reset-gzip-timestamps 'remove-readonly-gzip-files
+           (lambda* (#:key outputs #:allow-other-keys)
+             (for-each delete-file
+                       (find-files
+                        (assoc-ref outputs "out")
+                        ".*\\.gz")))))))
+    (synopsis "")
+    (description "")
+    (home-page "")
+    (license "")))
-- 
2.16.2





This bug report was last modified 91 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.