puppet node hostname

前端 未结 5 1448
暗喜
暗喜 2021-02-03 23:05

I\'m using puppet to configure servers. I want to print current machine (node) name in *.erb template. There is hostname variable, but this holds puppetmaster hostname.

5条回答
  •  既然无缘
    2021-02-03 23:40

    Do note though, this is the hostname rather than the node name (which you originally asked for). In 99% of cases, these will be the same. AFAIK there isn't a way to get the actual node name in templates (and if there is, I'd love to hear it).

提交回复
热议问题