gnu: Add distrobox.

* gnu/packages/containers.scm (distrobox): New variable.

Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
This commit is contained in:
Adam Faiz 2023-02-04 00:14:05 +01:00 committed by Nicolas Goaziou
parent 67b524360d
commit c3e50c731d
No known key found for this signature in database
GPG key ID: DA00B4F048E92F2D

View file

@ -26,6 +26,7 @@ (define-module (gnu packages containers)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module (guix build-system copy)
#:use-module (guix build-system gnu)
#:use-module (guix build-system go)
#:use-module (guix build-system meson)
@ -46,7 +47,8 @@ (define-module (gnu packages containers)
#:use-module (gnu packages selinux)
#:use-module (gnu packages version-control)
#:use-module (gnu packages virtualization)
#:use-module (gnu packages web))
#:use-module (gnu packages web)
#:use-module (gnu packages wget))
(define-public crun
(let ((commit "c381048530aa750495cf502ddb7181f2ded5b400"))
@ -153,6 +155,41 @@ (define-public conmon
runtime (like runc or crun) for a single container.")
(license license:asl2.0)))
(define-public distrobox
(package
(name "distrobox")
(version "1.4.2.1")
(source
(origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/89luca89/distrobox")
(commit version)))
(sha256
(base32 "0gs81m1bvlyq6ad22zsdsw1q6s3agy79vx94kdf6zjzngbanlydk"))
(file-name (git-file-name name version))))
(build-system copy-build-system)
(inputs
(list podman wget))
(arguments
(list #:phases
#~(modify-phases %standard-phases
(add-before 'install 'refer-to-inputs
(lambda* (#:key inputs #:allow-other-keys)
(substitute* (find-files "." "^distrobox.*")
(("podman") (search-input-file inputs "/bin/podman"))
(("wget") (search-input-file inputs "/bin/wget"))
(("command -v") "test -x"))))
(replace 'install
(lambda _
(invoke "./install" "--prefix" #$output))))))
(home-page "https://distrobox.privatedns.org/")
(synopsis "Create and start containers highly integrated with the hosts")
(description
"Distrobox is a fancy wrapper around Podman or Docker to create and start
containers highly integrated with the hosts.")
(license license:gpl3)))
(define-public libslirp
(package
(name "libslirp")