Skip to content
Snippets Groups Projects

Adding new audit event scope for instance level audit events

Merged Hitesh Raghuvanshi requested to merge 404730-instance-scope into master
All threads resolved!
11 files
+ 179
12
Compare changes
  • Side-by-side
  • Inline
Files
11
@@ -25,6 +25,18 @@ def find_object(destination_gid)
destination
end
def audit(destination, action:, extra_context: {})
audit_context = {
name: "#{action}_instance_event_streaming_destination",
author: current_user,
scope: Gitlab::Audit::InstanceScope.new,
target: destination,
message: "#{action.capitalize} instance event streaming destination #{destination.destination_url}"
}
::Gitlab::Audit::Auditor.audit(audit_context.merge(extra_context))
end
end
end
end
Loading