exttls

package
v1.13.2 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2026 License: MIT Imports: 9 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package exttls gives extensions one consistent way to configure the TLS settings of the clients they use to reach third-party services, which are often self-hosted behind self-signed certificates.

Two mechanisms are supported, the same in every extension:

  • STEADYBIT_EXTENSION_INSECURE_SKIP_VERIFY=true disables certificate verification.
  • Custom CA certificates are trusted by mounting them into the container and pointing SSL_CERT_DIR (or SSL_CERT_FILE) at them. Go reads these variables when it loads the system certificate pool, so no extension code is involved beyond not replacing that pool. The tls.Config returned here leaves RootCAs nil, which means the system pool.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClientConfig

func ClientConfig() *tls.Config

ClientConfig returns the tls.Config to use for outgoing connections to third-party services. Callers may modify the returned value, e.g. to add client certificates for mutual TLS.

func IsInsecureSkipVerify

func IsInsecureSkipVerify() bool

IsInsecureSkipVerify reports whether STEADYBIT_EXTENSION_INSECURE_SKIP_VERIFY is enabled. An empty or invalid value keeps verification on rather than failing startup, as charts may render the variable empty.

func Transport

func Transport() *http.Transport

Transport returns a clone of http.DefaultTransport with STEADYBIT_EXTENSION_INSECURE_SKIP_VERIFY applied on top of its TLS settings. Use it as the transport of an http.Client, or pass it to resty via SetTransport. Each call returns a transport with its own connection pool, so build it once per client.

If http.DefaultTransport was replaced by a wrapper (e.g. otelhttp), the standard transport captured at startup is used instead; the wrapper is not applied, wrap the result yourself if you need it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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