mirror of
https://github.com/super-linter/super-linter.git
synced 2024-11-06 09:15:49 -05:00
11b70102c3
- Run jscpd, gitleaks, textlint against the entire workspace instead of running them over single files, one by one. - Implement a warning function for deprecated variables. - Deprecate the VALIDATE_JSCPD_ALL_CODEBASE variable. - Remove duplicate configuration files when they are the same as the ones we provide in TEMPLATES. - Add a missing tests for ansible-lint. - Move ANSIBLE_DIRECTORY configuration when running tests in buildFileList, where similar configs are. - Simplify ansible-lint test cases to include only what's necessary, and not an entire set of roles, playbooks, and inventory. - Write instructions about major upgrades in the upgrade guide.
23 lines
920 B
Ruby
23 lines
920 B
Ruby
# frozen_string_literal: true
|
|
|
|
# Rails Console only
|
|
# This script will output all active webhooks currently being processed by an instance.
|
|
# Replace ARRAY_OF_URLS_CALLING_INSTANCE and GHES_URL with the appropriate values before running
|
|
|
|
# Prior to running this script, compile a list of the top URLs containing the phrase webhook
|
|
# This should be ran prior to entering the Rails Console with the command:
|
|
# grep -B1 --no-group-separator 'Faraday::TimeoutError' hookshot-logs/resqued.log | sed -n 1~2p |
|
|
# \ grep -v 'Faraday::TimeoutError: request timed out' | sort | uniq -c |sort -rn | head -n 20
|
|
|
|
File.open("/tmp/urls.txt", "w") do |file|
|
|
Hook.active.map do |h|
|
|
urls = [ARRAY_OF_URLS_CALLING_INSTANCE]
|
|
next if urls.include? h.url
|
|
|
|
begin
|
|
file.puts "https://GHES_URL/api/v3/repos/#{h.installation_target.full_name}/hooks/#{h.id}"
|
|
rescue StandardError => e
|
|
puts e.message
|
|
end
|
|
end
|
|
end
|