From: Timmy Douglas via Guix-patches via <guix-patches@gnu.org>
To: 52174@debbugs.gnu.org
Cc: ludo@gnu.org, mail@timmydouglas.com
Subject: [bug#52174] [PATCH v3 5/6] gnu: add cni-plugins
Date: Tue, 21 Dec 2021 23:33:54 -0800 [thread overview]
Message-ID: <4916a92131ef49b3264de4a049d78d18a2b2c91b.1640158278.git.mail@timmydouglas.com> (raw)
In-Reply-To: <87sfunjtfi.fsf@gnu.org>
* gnu/packages/containers.scm (cni-plugins): New variable.
---
gnu/packages/containers.scm | 45 +++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+)
diff --git a/gnu/packages/containers.scm b/gnu/packages/containers.scm
index 5e540bcfe4..2789dcfc7c 100644
--- a/gnu/packages/containers.scm
+++ b/gnu/packages/containers.scm
@@ -213,3 +213,48 @@ (define-public slirp4netns
(description
"slirp4netns provides user-mode networking (\"slirp\") for unprivileged network namespaces.")
(license license:gpl2+)))
+
+(define-public cni-plugins
+ (package
+ (name "cni-plugins")
+ (version "1.0.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/containernetworking/plugins")
+ (commit (string-append "v" version))))
+ (sha256
+ (base32 "1j91in0mg4nblpdccyq63ncbnn2pc2zzjp1fh3jy0bsndllgv0nc"))
+ (file-name (git-file-name name version))))
+ (build-system go-build-system)
+ (arguments
+ `(#:unpack-path "github.com/containernetworking/plugins"
+ #:tests? #f ; XXX: see stat /var/run below
+ #:phases (modify-phases %standard-phases
+ (replace 'build
+ (lambda _
+ (with-directory-excursion "src/github.com/containernetworking/plugins"
+ (invoke "./build_linux.sh"))))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ ; only pkg/ns tests run without root
+ (when tests?
+ (with-directory-excursion "src/github.com/containernetworking/plugins/pkg/ns"
+ (invoke "stat" "/var/run") ; XXX: test tries to stat this directory
+ (invoke "unshare" "-rmn" "go" "test")))))
+ (add-before 'check 'set-test-environment
+ (lambda _
+ (setenv "XDG_RUNTIME_DIR" "/tmp/cni-rootless")))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (copy-recursively "src/github.com/containernetworking/plugins/bin"
+ (string-append (assoc-ref outputs "out") "/bin")))))))
+ (native-inputs
+ (list util-linux))
+ (home-page "https://github.com/containernetworking/plugins")
+ (synopsis "Container Network Interface (CNI) network plugins")
+ (description
+ "Some Container Network Interface (CNI) network plugins, maintained by the
+containernetworking team.")
+ (license license:asl2.0)))
--
2.34.0
next prev parent reply other threads:[~2021-12-22 7:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <87sfunjtfi.fsf@gnu.org>
2021-12-22 7:33 ` [bug#52174] [PATCH v3 1/6] gnu: add crun Timmy Douglas via Guix-patches via
2021-12-22 7:33 ` [bug#52174] [PATCH v3 2/6] gnu: add conmon Timmy Douglas via Guix-patches via
2021-12-22 7:33 ` [bug#52174] [PATCH v3 3/6] gnu: add libslirp Timmy Douglas via Guix-patches via
2021-12-22 7:33 ` [bug#52174] [PATCH v3 4/6] gnu: add slirp4netns Timmy Douglas via Guix-patches via
2021-12-22 7:33 ` Timmy Douglas via Guix-patches via [this message]
2021-12-22 7:33 ` [bug#52174] [PATCH v3 6/6] gnu: add podman Timmy Douglas via Guix-patches via
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4916a92131ef49b3264de4a049d78d18a2b2c91b.1640158278.git.mail@timmydouglas.com \
--to=guix-patches@gnu.org \
--cc=52174@debbugs.gnu.org \
--cc=ludo@gnu.org \
--cc=mail@timmydouglas.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).