Documentation
¶
Overview ¶
Package cache provides a private OpenTofu/Terraform provider cache server.
Index ¶
- type Config
- type Option
- func WithCacheProviderHTTPStatusCode(statusCode int) Option
- func WithHostname(hostname string) Option
- func WithLogger(logger log.Logger) Option
- func WithPort(port int) Option
- func WithProviderHandlers(handlers ...handlers.ProviderHandler) Option
- func WithProviderService(service *services.ProviderService) Option
- func WithProxyProviderHandler(handler *handlers.ProxyProviderHandler) Option
- func WithToken(token string) Option
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
func (*Config) WithOptions ¶
type Option ¶
func WithCacheProviderHTTPStatusCode ¶ added in v0.73.15
func WithHostname ¶
func WithLogger ¶
func WithProviderHandlers ¶
func WithProviderHandlers(handlers ...handlers.ProviderHandler) Option
func WithProviderService ¶ added in v0.73.15
func WithProviderService(service *services.ProviderService) Option
func WithProxyProviderHandler ¶ added in v0.73.15
func WithProxyProviderHandler(handler *handlers.ProxyProviderHandler) Option
type Server ¶
type Server struct { *router.Router *Config ProviderController *controllers.ProviderController // contains filtered or unexported fields }
Server is a private Terraform cache for provider caching.
func (*Server) DiscoveryURL ¶
func (server *Server) DiscoveryURL(ctx context.Context, registryName string) (*handlers.RegistryURLs, error)
DiscoveryURL looks for the first handler that can handle the given `registryName`, which is determined by the include and exclude settings in the `.terraformrc` CLI config file. If the handler is found, tries to discover its API endpoints otherwise return the default registry URLs.
Directories
¶
Path | Synopsis |
---|---|
Package controllers provides the implementation of the controller for the provider endpoints.
|
Package controllers provides the implementation of the controller for the provider endpoints. |
Package handlers provides the interfaces and common implementations for handling provider requests.
|
Package handlers provides the interfaces and common implementations for handling provider requests. |
Package helpers provides utility functions for working with HTTP requests and responses.
|
Package helpers provides utility functions for working with HTTP requests and responses. |
Package middleware provides a set of middleware for the Terragrunt provider cache server.
|
Package middleware provides a set of middleware for the Terragrunt provider cache server. |
Package models provides the data structures used to represent Terraform providers and their details.
|
Package models provides the data structures used to represent Terraform providers and their details. |
Package router provides a simple wrapper around the echo framework to create a REST API.
|
Package router provides a simple wrapper around the echo framework to create a REST API. |
Package services provides services that can be run in the background.
|
Package services provides services that can be run in the background. |
Click to show internal directories.
Click to hide internal directories.