package
Version:
v1.21.0
Opens a new window with list of versions in this module.
Published: Feb 17, 2026
License: Apache-2.0
Opens a new window with license information.
Imports: 6
Opens a new window with list of imports.
Imported by: 1
Opens a new window with list of known importers.
README
¶
dockerHelpers
dockerHelpers provides utilities for detecting Docker environments and deploying startup payloads.
Functions
| Function |
Description |
IsDockerContainer() bool |
Returns true if /.dockerenv exists (i.e. running inside a Docker container) |
DeployDefaultsPayload() error |
Copies non-TOML files from startupPayload/ to ./data/defaults/ |
Example
import "github.com/mt1976/frantic-core/dockerHelpers"
func main() {
if dockerHelpers.IsDockerContainer() {
fmt.Println("Running in Docker")
if err := dockerHelpers.DeployDefaultsPayload(); err != nil {
log.Fatal(err)
}
}
}
Documentation
¶
Package dockerHelpers provides helpers to detect Docker environments and
interact with container-related metadata.
func DeployDefaultsPayload() error
func IsDockerContainer() bool
Source Files
¶
Click to show internal directories.
Click to hide internal directories.