chef-infra

How to check which java version is installed

喜你入骨 提交于 2020-07-23 08:06:38
问题 The chef client already has java installed on it. How can I check which version of java is installed using chef. I know I can write a small ohai plugin to do the same but is there any other way to check which java version is installed on the client? The java installation is not an rpm installation though on some endpoints it might be an rpm installation. 回答1: We already attempt to query it in Ohai for you: https://github.com/chef/ohai/blob/master/lib/ohai/plugins/java.rb However this is

How to check which java version is installed

跟風遠走 提交于 2020-07-23 08:06:28
问题 The chef client already has java installed on it. How can I check which version of java is installed using chef. I know I can write a small ohai plugin to do the same but is there any other way to check which java version is installed on the client? The java installation is not an rpm installation though on some endpoints it might be an rpm installation. 回答1: We already attempt to query it in Ohai for you: https://github.com/chef/ohai/blob/master/lib/ohai/plugins/java.rb However this is

How to check which java version is installed

人走茶凉 提交于 2020-07-23 08:04:20
问题 The chef client already has java installed on it. How can I check which version of java is installed using chef. I know I can write a small ohai plugin to do the same but is there any other way to check which java version is installed on the client? The java installation is not an rpm installation though on some endpoints it might be an rpm installation. 回答1: We already attempt to query it in Ohai for you: https://github.com/chef/ohai/blob/master/lib/ohai/plugins/java.rb However this is

Get Custom JSON from Stack Settings in AWS OpsWorks with Chef 12

江枫思渺然 提交于 2020-07-22 05:38:24
问题 I'm currently working on the OpsWorks stacks with Chef 12, writing my own deploying recipes. Is there any possibilities to get the content of the field "Custom JSON" in Stack Settings? Cheers, xiGUAwanOU 回答1: All that data gets set as node attributes, so you can access it as per normal via the node object. 来源: https://stackoverflow.com/questions/39707501/get-custom-json-from-stack-settings-in-aws-opsworks-with-chef-12

SQL Server can't auth user when installed witch chocolatey (via chef)

拟墨画扇 提交于 2020-07-21 03:58:05
问题 I am attempting to automate the installation of SQL Server 2016 Express. I have a chef cookbook to install SQL Server Express using the chocolatey package. The same command as a chef resource chocolatey_package 'sql-server-express' do action :install options '--cachelocation c:\temp\choco' end Equivalent PowerShell command choco install sql-server-express --cachelocation c:\temp\choco If I install SQL Server Express normally with the install wizard, I can authenticate and create / modify