aboutsummaryrefslogtreecommitdiff
path: root/.guix/modules/gn-auth.scm
blob: 9da988b49b133d34227c108c71e89d624bed547d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
(define-module (gn-auth)
  #:use-module (guix)
  #:use-module (guix gexp)
  #:use-module (guix packages)
  #:use-module (guix download)
  #:use-module (guix git-download)
  #:use-module (guix build-system python)
  #:use-module ((guix licenses) #:prefix license:)

  ;; Packages from guix
  #:use-module (gnu packages check)

  #:use-module (gnu packages django)

  #:use-module (gnu packages python-web)
  #:use-module (gnu packages python-xyz)
  #:use-module (gnu packages python-check)
  #:use-module (gnu packages python-crypto)

  #:use-module (gnu packages databases)

  ;; Packages from guix-bioinformatics
  #:use-module (gn packages python)
  #:use-module (gn packages python-web))

(define %source-dir (dirname (dirname (current-source-directory))))

(define vcs-file?
  (or (git-predicate %source-dir)
      (const #t)))

(define-public gn-auth
  (package
    (name "gn-auth")
    (version "0.1.0-git")
    (source
     (local-file "../.."
		 "gn-auth-checkout"
		 #:recursive? #t
		 #:select? vcs-file?))
    (build-system python-build-system)
    (arguments
     (list
      #:phases
      #~(modify-phases %standard-phases
	  (replace 'check
	    (lambda* (#:key tests? #:allow-other-keys)
	      (when tests?
		(invoke "pytest" "-k" "unit_test")))))))
    (native-inputs
     `(("python-mypy" ,python-mypy-0.981)
       ("python-pytest" ,python-pytest)
       ("python-pylint" ,python-pylint)
       ("python-hypothesis" ,python-hypothesis)
       ("python-pytest-mock" ,python-pytest-mock)
       ("python-mypy-extensions" ,python-mypy-extensions)))
    (propagated-inputs
     `(("gunicorn" ,gunicorn)
       ("python-flask" ,python-flask)
       ("python-redis" ,python-redis)
       ("python-authlib" ,python-authlib)
       ("python-pymonad" ,python-pymonad)
       ("yoyo-migrations" ,yoyo-migrations-8.2.0)
       ("python-bcrypt" ,python-bcrypt) ;; remove after removing all references
       ("python-mysqlclient" ,python-mysqlclient)
       ("python-argon2-cffi" ,python-argon2-cffi)
       ("python-email-validator" ,python-email-validator)))
    (home-page "https://github.com/genenetwork/gn-auth")
    (synopsis "Authentication and Authorisation server for GeneNetwork services")
    (description "Authentication and Authorisation server for GeneNetwork services.")
    (license license:agpl3+)))

gn-auth