I am having syntax errors and I am unsure how to resolve them. In the roles file I have defined the fallowing:
default_attributes(
'jdk' => {
'version' => '1.8.0_31'
},
'java' => {
'home' => '/usr/lib/jvm/jdk1.8.0_31'
},
)
I try to use the java home in the following, but it fails to run
execute "update_alt_java" do
command "update-alternatives --install "/usr/bin/java" "java" "#{node['java']['home']}/bin/java" 1"
action :creates
end
I get the following error
SyntaxError
-----------
/etc/chef/src/cookbooks/jdk/recipes/default.rb:50: syntax error, unexpected tSTRING_BEG, expecting keyword_do or '{' or '('
...tives --install "/usr/bin/java" "java" "#{node['java']['home...
... ^
/etc/chef/src/cookbooks/jdk/recipes/default.rb:50: syntax error, unexpected tIDENTIFIER, expecting keyword_end
...--install "/usr/bin/java" "java" "#{node['java']['home']}/bi...