Documentation
¶
Overview ¶
Package hostnameinterface describes the interface for hostname methods
Index ¶
Constants ¶
View Source
const ( // ConfigProvider is the default provider value from the configuration file ConfigProvider = "configuration" // FargateProvider is the default provider value from Fargate FargateProvider = "fargate" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Component ¶
type Component interface { // Get returns the host name for the agent. Get(context.Context) (string, error) // GetWithProvider returns the hostname for the Agent and the provider that was use to retrieve it. GetWithProvider(ctx context.Context) (Data, error) // GetSafe is Get(), but it returns 'unknown host' if anything goes wrong. GetSafe(context.Context) string }
Component is the type for hostname methods.
type Data ¶
Data contains hostname and the hostname provider
func (Data) FromConfiguration ¶
FromConfiguration returns true if the hostname was found through the configuration file
func (Data) FromFargate ¶
FromFargate returns true if the hostname was found through Fargate
Click to show internal directories.
Click to hide internal directories.