mechanism to report spam ips to stopforumspam

This commit is contained in:
Kyle Drake 2017-01-11 17:16:40 -06:00
parent 7be37ce595
commit bedc08cb58
10 changed files with 38 additions and 25 deletions

View file

@ -0,0 +1,10 @@
class StopForumSpamWorker
include Sidekiq::Worker
sidekiq_options queue: :stop_forum_spam, retry: 1, backtrace: true
def perform(opts)
opts.merge! api_key: $config['stop_forum_spam_api_key']
res = HTTP.post 'https://stopforumspam.com/add', opts
puts res.inspect
end
end