mirror of
https://github.com/go-micro/go-micro.git
synced 2025-11-29 21:47:44 +02:00
fix: struct field alignment (#2632)
This commit is contained in:
@@ -10,17 +10,9 @@ type Option func(o *Options)
|
||||
|
||||
// Options represents various options you can present to ACME providers.
|
||||
type Options struct {
|
||||
// AcceptTLS must be set to true to indicate that you have read your
|
||||
// provider's terms of service.
|
||||
AcceptToS bool
|
||||
// CA is the CA to use
|
||||
CA string
|
||||
// ChallengeProvider is a go-acme/lego challenge provider. Set this if you
|
||||
// want to use DNS Challenges. Otherwise, tls-alpn-01 will be used
|
||||
ChallengeProvider challenge.Provider
|
||||
// Issue certificates for domains on demand. Otherwise, certs will be
|
||||
// retrieved / issued on start-up.
|
||||
OnDemand bool
|
||||
// Cache is a storage interface. Most ACME libraries have an cache, but
|
||||
// there's no defined interface, so if you consume this option
|
||||
// sanity check it before using.
|
||||
@@ -28,6 +20,14 @@ type Options struct {
|
||||
|
||||
// Logger is the underling logging framework
|
||||
Logger logger.Logger
|
||||
// CA is the CA to use
|
||||
CA string
|
||||
// AcceptTLS must be set to true to indicate that you have read your
|
||||
// provider's terms of service.
|
||||
AcceptToS bool
|
||||
// Issue certificates for domains on demand. Otherwise, certs will be
|
||||
// retrieved / issued on start-up.
|
||||
OnDemand bool
|
||||
}
|
||||
|
||||
// AcceptToS indicates whether you accept your CA's terms of service.
|
||||
|
||||
@@ -6,9 +6,9 @@ import (
|
||||
|
||||
type Config struct {
|
||||
AllowOrigin string
|
||||
AllowCredentials bool
|
||||
AllowMethods string
|
||||
AllowHeaders string
|
||||
AllowCredentials bool
|
||||
}
|
||||
|
||||
// CombinedCORSHandler wraps a server and provides CORS headers.
|
||||
|
||||
@@ -15,12 +15,13 @@ import (
|
||||
)
|
||||
|
||||
type httpServer struct {
|
||||
mux *http.ServeMux
|
||||
opts server.Options
|
||||
|
||||
mtx sync.RWMutex
|
||||
address string
|
||||
mux *http.ServeMux
|
||||
exit chan chan error
|
||||
address string
|
||||
|
||||
mtx sync.RWMutex
|
||||
}
|
||||
|
||||
func NewServer(address string, opts ...server.Option) server.Server {
|
||||
|
||||
@@ -13,16 +13,16 @@ import (
|
||||
type Option func(o *Options)
|
||||
|
||||
type Options struct {
|
||||
ACMEProvider acme.Provider
|
||||
Resolver resolver.Resolver
|
||||
Logger logger.Logger
|
||||
CORSConfig *cors.Config
|
||||
TLSConfig *tls.Config
|
||||
ACMEHosts []string
|
||||
Wrappers []Wrapper
|
||||
EnableACME bool
|
||||
EnableCORS bool
|
||||
CORSConfig *cors.Config
|
||||
ACMEProvider acme.Provider
|
||||
EnableTLS bool
|
||||
ACMEHosts []string
|
||||
TLSConfig *tls.Config
|
||||
Resolver resolver.Resolver
|
||||
Wrappers []Wrapper
|
||||
Logger logger.Logger
|
||||
}
|
||||
|
||||
type Wrapper func(h http.Handler) http.Handler
|
||||
|
||||
Reference in New Issue
Block a user