Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在编写一个 shell 脚本来version.txt从 AWS S3 存储桶下载文件。
version.txt
在 shell 脚本中,我需要使用 Puppet Facter 值(例如env_name和product_name)。如何在我的 shell 脚本中获取这些 Facter 值?
env_name
product_name
运行facter env_name以检索值:
facter env_name
env_name=$(facter env_name) echo $env_name
如果这是来自 Puppet 模块(通过 pluginsync)的事实,请添加-p参数:
-p
env_name=$(facter -p env_name)