AppSignal v1.9.2 Appsignal.Config View Source
Link to this section Summary
Functions
Returns true if the configuration is valid and the AppSignal agent is configured to start on application launch
Returns whether the AppSignal agent is configured to start on application launch
Initializes the AppSignal config. Looks at the config default, the
Elixir-provided configuration and the various APPSIGNAL_*
OS environment variables. Returns whether or not the configuration is valid
Reset the config written to the environment by write_to_environment/1
.
This makes sure no existing config gets reused and the configuration for the
agent gets set again
Write the currently known AppSignal configuration to the system environment. Must be run before starting the AppSignal agent otherwise it won't know the correct configuration
Link to this section Functions
active?()
View Source
active?() :: boolean()
active?() :: boolean()
Returns true if the configuration is valid and the AppSignal agent is configured to start on application launch.
ca_file_path() View Source
configured_as_active?()
View Source
configured_as_active?() :: boolean()
configured_as_active?() :: boolean()
Returns whether the AppSignal agent is configured to start on application launch.
get_system_env() View Source
initialize()
View Source
initialize() :: :ok | {:error, :invalid_config}
initialize() :: :ok | {:error, :invalid_config}
Initializes the AppSignal config. Looks at the config default, the
Elixir-provided configuration and the various APPSIGNAL_*
OS environment variables. Returns whether or not the configuration is valid.
log_file_path() View Source
request_headers() View Source
reset_environment_config!() View Source
Reset the config written to the environment by write_to_environment/1
.
This makes sure no existing config gets reused and the configuration for the
agent gets set again.
write_to_environment() View Source
Write the currently known AppSignal configuration to the system environment. Must be run before starting the AppSignal agent otherwise it won't know the correct configuration.
Example
case {Appsignal.Config.initialize, Appsignal.Config.active?} do
{:ok, true} ->
Appsignal.Config.write_to_environment
Appsignal.Nif.start
{:ok, false} ->
# AppSignal not active
{{:error, :invalid_config}, _} ->
# AppSignal has invalid config
end