We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
This will loop through and disable every policy in the JSS.
JSS::Policy.all_ids(:refresh) do |pol_id| pol = JSS::Policy.fetch id: pol_id next unless pol.enabled? pol.disable pol.save puts "Disabled Policy '#{pol.name}', id: #{pol_id} " end
ruby-jss Wiki Home