/usr/lib/python2.7/dist-packages/charmtools/templates/chef/files/cookbooks/juju-helpers/definitions/relation_set.rb is in charm-tools 2.1.2-0ubuntu4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 | define :relation_set do
args_string = params[:variables].map { |key, value| "#{key}=\"#{value}\"" }.join(' ')
command = "relation-set #{args_string}"
command += " -r #{params[:relation_id]}" if params[:relation_id]
execute command do
action :run
end
end
|