dockerHelpers

package
v1.22.0 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2026 License: Apache-2.0 Imports: 6 Imported by: 1

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

Overview

Package dockerHelpers provides helpers to detect Docker environments and interact with container-related metadata.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeployDefaultsPayload

func DeployDefaultsPayload() error

func IsDockerContainer

func IsDockerContainer() bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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