Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrGeneratingCert is returned when there's a failure generating a new certificate. ErrGeneratingCert = errors.New("an error occurred while generating the certificate, please check the log for more information") // ErrTOSNotAccepted is returns if the acceptTOS was set to false and the account has never accepted the TOS. ErrTOSNotAccepted = errors.New("Let's encrypt terms of service was not accepted") )
View Source
var ErrLockExists = errors.New("was unable to grab a lock, lock already exists")
ErrLockExists is returned if unable to grab a lock.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct { // CertChan is the channel where the service sends out the certificate at the // retrieval and at the renewal time. CertChan chan *legoetcd.Cert // StopChan if closed will stop the service. StopChan chan struct{} // KeyType is the crypto type for the key, Supported: rsa2048, rsa4096, // rsa8192, ec256, ec384. KeyType acme.KeyType // NoBundle disables bundling of the issuer certificate along with the // domain's certificate. NoBundle bool // contains filtered or unexported fields }
Service represents a lego-etcd service that is able to manage the certificate for the given domains by generating certificates through Let's encrypt, storing them in etcd and renew them as well. The service is fully managed.
func New ¶
func New(etcdConfig client.Config, acmeServer, email string, domains []string, csrFile string, acceptTOS, generatePEM bool, dns, webroot string) *Service
New returns a new service, the default keyType is RSA2048 but you may change by setting the KeyType on the returned service. By default, the service will generate a bundled certificate (containing the issuer certificate and your certificate). To disable bundling, set `NoBundle` to true.
Click to show internal directories.
Click to hide internal directories.