mirror of
https://github.com/Start9Labs/registry.git
synced 2026-03-26 10:21:51 +00:00
implements basic authentication for admins
This commit is contained in:
14
src/Model.hs
14
src/Model.hs
@@ -11,9 +11,11 @@
|
||||
|
||||
module Model where
|
||||
|
||||
import Crypto.Hash
|
||||
import Database.Persist.TH
|
||||
import Lib.Types.AppIndex
|
||||
import Lib.Types.Emver
|
||||
import Orphans.Cryptonite ( )
|
||||
import Orphans.Emver ( )
|
||||
import Startlude
|
||||
|
||||
@@ -100,4 +102,16 @@ PkgDependency
|
||||
UniquePkgDepVersion pkgId pkgVersion depId
|
||||
deriving Eq
|
||||
deriving Show
|
||||
|
||||
Admin
|
||||
createdAt UTCTime
|
||||
name Text
|
||||
passHash (Digest SHA256)
|
||||
UniqueAdmin name
|
||||
|
||||
Upload
|
||||
uploader AdminId
|
||||
pkgId PkgRecordId
|
||||
pkgVersion Version
|
||||
createdAt UTCTime
|
||||
|]
|
||||
|
||||
Reference in New Issue
Block a user