Skip to content

can't convert Chef::Resource::JavaProperties to Array (Chef::Resource::JavaProperties#to_ary gives String) #2

@kleini

Description

@kleini

Whe trying to use the java_properties resource with the Chef notifies or subscribe mechanism I get always the following exception:

`================================================================================
Recipe Compile Error in /tmp/kitchen/cache/cookbooks/deployment-development-connect2id/recipes/default.rb
================================================================================

   TypeError
   ---------
   can't convert Chef::Resource::JavaProperties to Array (Chef::Resource::JavaProperties#to_ary gives String)
   
   Cookbook Trace:
   ---------------
     /tmp/kitchen/cache/cookbooks/deployment-development-connect2id/recipes/default.rb:71:in `block in from_file'
     /tmp/kitchen/cache/cookbooks/deployment-development-connect2id/recipes/default.rb:66:in `from_file'
   
   Relevant File Content:
   ----------------------
   /tmp/kitchen/cache/cookbooks/deployment-development-connect2id/recipes/default.rb:
   
    64:  end
    65:  
    66:  java_properties 'oidcProvider' do
    67:    properties_file '/opt/connect2id-server-6.16/tomcat/webapps/c2id/WEB-INF/oidcProvider.properties'
    68:    property 'op.logout.sessionLifetime', '40'
    69:    property 'op.logout.endpoint', 'http://127.0.0.1:8080/c2id-login/c2id-logout-page-jsp/'
    70:    only_if { ::File.exist?('/opt/connect2id-server-6.16/tomcat/webapps/c2id/WEB-INF/oidcProvider.properties') }
    71>>   subscribes :start, 'systemd_unit[tomcat.service]'
    72:    notifies :restart, 'systemd_unit[tomcat.service]', :delayed
    73:  end
    74:  
   
   System Info:
   ------------
   chef_version=13.7.16
   platform=debian
   platform_version=9.2
   ruby=ruby 2.4.3p205 (2017-12-14 revision 61247) [x86_64-linux]
   program_name=chef-solo worker: ppid=8421;start=09:37:56;
   executable=/opt/chef/bin/chef-solo

`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions