Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
end

chef_gem 'influxdb' do
version '0.6.1'
version '0.8.1'
compile_time false if respond_to?(:compile_time)
end

Expand Down
10 changes: 8 additions & 2 deletions resources/config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,16 @@
default_action :create

action :create do
require 'toml'
if Version.new(Chef::VERSION) >= Version.new('17.3.48')
content = render_toml(new_resource.config)
else
require 'toml'

content = TOML::Generator.new(new_resource.config).body
end

file new_resource.path do
content TOML::Generator.new(new_resource.config).body
content content
end
end

Expand Down