From f66335f354170acd92ba9a929de97a8909e050b5 Mon Sep 17 00:00:00 2001 From: JEAN-FRANCOIS GUILLAUME Date: Thu, 9 Feb 2023 22:12:01 +0100 Subject: [PATCH] adding up-to-date gitlab-runner from hpc-non-free --- glicid/packages/gitlab.scm | 44 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 glicid/packages/gitlab.scm diff --git a/glicid/packages/gitlab.scm b/glicid/packages/gitlab.scm new file mode 100644 index 0000000..804c4f9 --- /dev/null +++ b/glicid/packages/gitlab.scm @@ -0,0 +1,44 @@ +(define-module (glicid packages gitlab) + #:use-module (guix) + #:use-module (ice-9 match) + #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix utils) + #:use-module (guix download) + #:use-module (guix packages) + #:use-module (guix build-system trivial) + #:use-module (gnu packages bash) + #:use-module (gnu packages version-control)) + +(define-public gitlab-runner + (package + (name "gitlab-runner") + (version "15.8.1") + (source (origin + (method url-fetch) + (uri (string-append "https://" name "-downloads.s3.amazonaws.com/v" version "/binaries/" name "-linux-amd64")) + (file-name (string-append name "-linux-amd64")) + (sha256 (base32 "0dbkji70wxn61q1zkayr4al365lz09nd1f8b06dady3yfplr91yv")))) + (build-system trivial-build-system) + (arguments + '(#:modules ((guix build utils)) + #:builder (begin + (use-modules (guix build utils)) + (let* ((source (assoc-ref %build-inputs "source")) + (out (assoc-ref %outputs "out")) + (install-dir (string-append out "/bin")) + (executable (string-append install-dir "/gitlab-runner")) + (bash (string-append (assoc-ref %build-inputs "bash") "/bin/")) + (git-dir (string-append (assoc-ref %build-inputs "git") "/bin/"))) + (setenv "PATH" (string-append (getenv "PATH") ":" bash)) + (mkdir-p install-dir) + (copy-file source executable) + (chmod executable #o555) + (wrap-program executable `("PATH" ":" prefix (,git-dir))))))) + (inputs (list git bash)) + (synopsis "Gitlab Runner") + (description + "The official GitLab Runner written in Go. It runs tests and sends the + results to GitLab. GitLab CI is the open-source continuous integration + service included with GitLab that coordinates the testing.") + (home-page "https://gitlab.com/gitlab-org/gitlab-runner") + (license license:expat)))