我在学习木偶,我在尝试更新bash (没有猜测原因的奖励)。
这在我的site.pp里
file { "/etc/apt/sources.list.d/shellshock.list":
source => "puppet:///files/shellshock.list",
owner => "root",
group => "root",
mode => "0644",
ensure => present,
}
->
exec { "instantRepoUpdate":
command => "/usr/bin/aptitude update",
refreshonly => true,
}
->
package {"bash": ensure => latest, }从我在这里阅读的内容来看,https://docs.puppetlabs.com/puppet/latest/reference/lang_relationships.html应该翻译成:
安装/etc/apt/sources.list.d/shellshock.list,然后运行智能更新,然后确保bash在最新版本上
是的,但只运行了两次。我希望它在一次运行中按照顺序执行所有三个操作。
更新:我尝试添加“需要=> Exec[.,需要=>文件[.]”对于exec和package资源,我得到了相同的结果。
发布于 2014-10-01 11:25:08
您设置了refreshonly => true,因此需要使用通知箭头(~>)。
https://serverfault.com/questions/632699
复制相似问题