Safe Haskell | None |
---|---|
Language | Haskell98 |
Propellor.Types.PrivData
- data PrivDataField
- data PrivDataSource
- type PrivDataSourceDesc = String
- class IsPrivDataSource s where
- privDataField :: s -> PrivDataField
- describePrivDataSource :: s -> Maybe PrivDataSourceDesc
- newtype Context = Context String
- newtype HostContext = HostContext {
- mkHostContext :: HostName -> Context
- class IsContext c where
- asContext :: HostName -> c -> Context
- asHostContext :: c -> HostContext
- anyContext :: Context
- hostContext :: HostContext
- type PrivData = String
- data SshKeyType
- = SshRsa
- | SshDsa
- | SshEcdsa
- | SshEd25519
- sshKeyTypeParam :: SshKeyType -> String
- data DnsSecKey
Documentation
data PrivDataField Source
Note that removing or changing constructors or changing types will break the serialized privdata files, so don't do that! It's fine to add new constructors.
Constructors
DockerAuthentication | |
SshPubKey SshKeyType UserName | |
SshPrivKey SshKeyType UserName | For host key, use empty UserName |
SshAuthorizedKeys UserName | |
Password UserName | |
CryptPassword UserName | |
PrivFile FilePath | |
GpgKey | |
DnsSec DnsSecKey |
data PrivDataSource Source
Combines a PrivDataField with a description of how to generate its value.
Constructors
PrivDataSourceFile PrivDataField FilePath | |
PrivDataSourceFileFromCommand PrivDataField FilePath String | |
PrivDataSource PrivDataField String |
Instances
type PrivDataSourceDesc = String Source
class IsPrivDataSource s where Source
Methods
privDataField :: s -> PrivDataField Source
describePrivDataSource :: s -> Maybe PrivDataSourceDesc Source
A context in which a PrivDataField is used.
Often this will be a domain name. For example, Context "www.example.com" could be used for the SSL cert for the web server serving that domain. Multiple hosts might use that privdata.
This appears in serialized privdata files.
newtype HostContext Source
A context that varies depending on the HostName where it's used.
Constructors
HostContext | |
Fields
|
Instances
Use when a PrivDataField is not dependent on any paricular context.
hostContext :: HostContext Source
Makes a HostContext that consists just of the hostname.
data SshKeyType Source
Constructors
SshRsa | |
SshDsa | |
SshEcdsa | |
SshEd25519 |
sshKeyTypeParam :: SshKeyType -> String Source
Parameter that would be passed to ssh-keygen to generate key of this type