aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/backup.scm
diff options
context:
space:
mode:
authorAndreas Enge <andreas@enge.fr>2023-04-23 22:21:00 +0200
committerAndreas Enge <andreas@enge.fr>2023-04-23 22:21:00 +0200
commitd7ec2805fbb7fe39e2c66588baef0454aeb42548 (patch)
tree132e79661fd9b3c1dbe146537b00bd1412cb55cb /gnu/packages/backup.scm
parent480a125bde4c1a568c2b1254136a00bc20a0e399 (diff)
parent74e96c4cb171b17949f638d8b452d047a8f2dc6f (diff)
downloadguix-d7ec2805fbb7fe39e2c66588baef0454aeb42548.tar
guix-d7ec2805fbb7fe39e2c66588baef0454aeb42548.tar.gz
Merge remote-tracking branch 'origin/master' into core-updates
Diffstat (limited to 'gnu/packages/backup.scm')
-rw-r--r--gnu/packages/backup.scm48
1 files changed, 48 insertions, 0 deletions
diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index b545b9c370..7f44008b52 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -23,6 +23,7 @@
;;; Copyright © 2021 Sarah Morgensen <iskarian@mgsn.dev>
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2022 Feng Shu <tumashu@163.com>
+;;; Copyright © 2023 Timo Wilken <guix@twilken.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1019,6 +1020,53 @@ precious backup space.
@end itemize")
(license license:bsd-2)))
+(define-public restic-rest-server
+ (package
+ (name "restic-rest-server")
+ (version "0.11.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/restic/rest-server")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1nvmxc9x0mlks6yfn66fmwn50k5q83ip4g9vvb0kndzd7hwcyacy"))))
+ (build-system go-build-system)
+ (arguments
+ '(#:import-path "github.com/restic/rest-server/cmd/rest-server"
+ #:unpack-path "github.com/restic/rest-server"
+ #:install-source? #f ;all we need is the binary
+ #:phases (modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys . args)
+ (when tests?
+ ;; Unit tests seems to break with Guix' non-standard TMPDIR.
+ (setenv "TMPDIR" "/tmp")
+ (apply (assoc-ref %standard-phases
+ 'check) args))))
+ (add-after 'install 'rename-binary
+ (lambda* (#:key outputs #:allow-other-keys)
+ (with-directory-excursion (assoc-ref outputs "out")
+ ;; "rest-server" is a bit too generic.
+ (rename-file "bin/rest-server"
+ "bin/restic-rest-server")))))))
+ (propagated-inputs (list go-golang-org-x-crypto
+ go-github-com-spf13-cobra
+ go-github-com-prometheus-client-golang
+ go-github-com-miolini-datacounter
+ go-github-com-minio-sha256-simd
+ go-github-com-gorilla-handlers
+ go-github-com-coreos-go-systemd-activation))
+ (home-page "https://github.com/restic/rest-server")
+ (synopsis "Restic REST server")
+ (description
+ "The Restic REST server is a high performance HTTP server that implements
+restic's REST backend API. It provides a secure and efficient way to backup
+data remotely, using the restic backup client and a @code{rest:} URL.")
+ (license license:bsd-2)))
+
(define-public zbackup
(package
(name "zbackup")