cert

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 28, 2021 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UpdateCertificates

func UpdateCertificates(caURL, acmednsURL, hetznerAPIToken string)

UpdateCertificates updates all certificates for configured certificate requests if required.

Types

type ACMEDNS

type ACMEDNS struct {
	Username   string   `json:"username"`
	Password   string   `json:"password"`
	FullDomain string   `json:"full_domain"`
	SubDomain  string   `json:"sub_domain"`
	Domains    []string `json:"domains"`
}

ACMEDNS is the configuration for acme-dns.

type Cert

type Cert struct {
	certificate.Resource

	PrivateKey        string `json:"private_key"`
	Certificate       string `json:"certificate"`
	IssuerCertificate string `json:"issuer_certificate"`
	CSR               string `json:"csr"`

	Hetzner    Hetzner   `json:"hetzner"`
	NextUpdate time.Time `json:"next_update"`
}

Cert is a certificate obtained from Letsencrypt.

type CertRequest

type CertRequest struct {
	Email   string  `json:"email"`
	ACMEDNS ACMEDNS `json:"acmedns"`
	Hetzner Hetzner `json:"hetzner"`
}

CertRequest is the configuration for a certificate request.

type Hetzner

type Hetzner struct {
	Name   string            `json:"name"`
	Labels map[string]string `json:"labels"`
	LBName string            `json:"lb_name"`
	LBPort int               `json:"lb_port"`
}

Hetzner is the configuration for Hetzner.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL