MCPcopy Create free account
hub / github.com/Unpackerr/unpackerr / isRunningInDocker

Function isRunningInDocker

pkg/unpackerr/cnfgfile.go:260–264  ·  view source on GitHub ↗

only run this once.

()

Source from the content-addressed store, hash-verified

258
259// only run this once.
260func isRunningInDocker() bool {
261 // docker creates a .dockerenv file at the root of the container.
262 _, err := os.Stat("/.dockerenv")
263 return err == nil
264}
265
266// expandHomedir expands a ~ to a homedir, or returns the original path in case of any error.
267func expandHomedir(filePath string) string {

Callers 2

PollFoldersMethod · 0.85
createConfigFileMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected