32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
# File 'lib/chef/knife/acl_show.rb', line 32
def run
object_type, object_name = name_args
if name_args.length != 2
show_usage
ui.fatal "You must specify an object type and object name"
exit 1
end
validate_object_type!(object_type)
validate_object_name!(object_name)
acl = get_acl(object_type, object_name)
PERM_TYPES.each do |perm|
if acl[perm].key?("users") && acl[perm].key?("clients")
acl[perm].delete "actors"
end
end
ui.output acl
end
|