env

package
v0.3.13 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package env provides environment variables parsing and utils builders

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildProxyDialer

func BuildProxyDialer(proxyURL *url.URL) func(ctx context.Context, network string, addr string) (net.Conn, error)

BuildProxyDialer builds a proxy dialler from url

func GetAPIKey added in v0.1.16

func GetAPIKey() (string, error)

GetAPIKey returns the escape api key or an error if it is not set

func GetAPIURL added in v0.1.16

func GetAPIURL() (*url.URL, error)

GetAPIURL returns the escape api url Default to https://public.escape.tech if not set

func GetBackendProxyURL

func GetBackendProxyURL() *url.URL

GetBackendProxyURL returns the proxy between the location and the customer API

func GetCertificates added in v0.2.0

func GetCertificates() (*tls.Config, error)

GetCertificates returns the SSL certificates to use in the HTTP client

func GetColorPreference added in v0.3.10

func GetColorPreference() bool

GetColorPreference returns the color preference Default to true if not set

func GetFrontendProxyURL

func GetFrontendProxyURL() *url.URL

GetFrontendProxyURL returns the proxy between the location and the Escape Platform

func GetHTTPClient added in v0.1.16

func GetHTTPClient() *http.Client

GetHTTPClient returns a new http client with the proxy set if needed This client should be used for calls to the Escape Platform

Types

This section is empty.

Jump to

Keyboard shortcuts

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