已经安装了Check Check软件包

问题描述 投票:0回答:1

食谱

cookbook_file '/tmp/awscli-exe-linux-x86_64.zip' do source 'awscli-exe-linux-x86_64.zip' owner 'root' group 'root' mode '0755' action :create notifies :run, "bash[install_awscli]", :immediately end

bash "install_awscli" do user "root" cwd "/tmp" code <<-EOH unzip awscli-exe-linux-x86_64.zip (sudo ./aws/install && aws --version) EOH action :nothing end

错误an "bash" "/tmp/chef-script20200510-1596-1thl7p2" returned 1

我的问题是,检查某个软件包是否已经安装以便不会从配方中重新安装的正确方法是什么?

chef devops chef-recipe
1个回答
0
投票

将目录从/tmp更改为某些持久目录可解决此问题。。

© www.soinside.com 2019 - 2024. All rights reserved.