Documentation
¶
Index ¶
- Variables
- type Config
- type KeyStore
- func (instance KeyStore) Ca() []*x509.Certificate
- func (instance KeyStore) Config() Config
- func (instance KeyStore) GeneratePem(name string) ([]byte, *x509.Certificate, error)
- func (instance KeyStore) IsCA() bool
- func (instance KeyStore) IsEnabled() bool
- func (instance KeyStore) LoadCertificateFromFile(filename string) (*x509.Certificate, error)
- func (instance KeyStore) Pem() []byte
- func (instance KeyStore) Type() Type
- type Type
- func (i Type) CheckedString() (string, error)
- func (i Type) IsConsumingCaFile() bool
- func (i Type) IsGenerating() bool
- func (i Type) IsTakingFilename() bool
- func (i Type) MarshalJSON() ([]byte, error)
- func (i Type) MarshalYAML() (interface{}, error)
- func (i *Type) Set(value string) error
- func (i Type) String() string
- func (i *Type) UnmarshalJSON(b []byte) error
- func (i *Type) UnmarshalYAML(unmarshal func(interface{}) error) error
- func (i Type) Validate() error
Constants ¶
This section is empty.
Variables ¶
View Source
var AllTypes = []Type{ Generated, FromFile, FromEnvironment, }
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // @default generated // // Defines the type of instance keyStore. Type Type `json:"type" yaml:"type"` // @default "" // // Defines the pemFile which contains the key and certificate to use. // This have to be of type PEM and have to contain the certificate and private key. // Currently the private key is only supported of type RSA. // // This property is only evaluated and required if {@ref #Type type} is set to // {@ref .Type#FromFile fromFile}. PemFile String `json:"pemFile,omitempty" yaml:"pemFile"` // @default "algorithm:`rsa` bits:`1024`" // // Defines some hints for instance store in format “[<key:`value`>...]“. // Possible hints are: // // * “algorithm“: Algorithm to use for creation of new keys. Currently only “rsa“ is supported. // * “bits“: Number of bits to create a new key with. Hints String `json:"hints,omitempty" yaml:"hints"` // @default "" // // File where trusted certificates are stored in. This have to be in PEM format. CaFile String `json:"caFile,omitempty" yaml:"caFile"` }
Description ¶
Defines the keyStore of caretakerd.
func (Config) GetKeyArgument ¶
type KeyStore ¶
type KeyStore struct {
// contains filtered or unexported fields
}
func (KeyStore) Ca ¶
func (instance KeyStore) Ca() []*x509.Certificate
func (KeyStore) GeneratePem ¶
func (KeyStore) LoadCertificateFromFile ¶
func (instance KeyStore) LoadCertificateFromFile(filename string) (*x509.Certificate, error)
type Type ¶
type Type int
Description ¶
Represents the type of the keyStore.
const ( // @id generated // Indicates that caretakerd have to generate its own keyStore on startup. // This is the best solution in most cases. Generated Type = 0 // @id fromFile // Load keyStore from a provided PEM file. // If instance type is selected instance file have to be provided. FromFile Type = 1 // @id fromEnvironment // Load keyStore from the environment variable “CTD_PEM“ in PEM format. // If instance type is selected instance variable have to be provided. FromEnvironment Type = 2 )
func (Type) CheckedString ¶
func (Type) IsConsumingCaFile ¶
func (Type) IsGenerating ¶
func (Type) IsTakingFilename ¶
func (Type) MarshalJSON ¶
func (Type) MarshalYAML ¶
func (*Type) UnmarshalJSON ¶
func (*Type) UnmarshalYAML ¶
Click to show internal directories.
Click to hide internal directories.