hostname

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExpandHostnamePattern

func ExpandHostnamePattern(pattern string, nid int64, id string) string

ExpandHostnamePattern replaces {Nd} with zero-padded NID and {id} with xname Example patterns:

  • "nid{04d}" with NID=1 => "nid0001"
  • "dev-s{02d}" with NID=5 => "dev-s05"
  • "bmc{03d}" with NID=42 => "bmc042"
  • "{id}" with xname="x3000c0s0b1" => "x3000c0s0b1"

Types

This section is empty.

Jump to

Keyboard shortcuts

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