Commit cfe3cfb3 authored by Andrew Newdigate's avatar Andrew Newdigate

Adding chaos to GitLab through chaos endpoints

parent e62168fc
# frozen_string_literal: true
class ChaosController < ActionController::Base
def sleep
duration_s = params[:duration_s] ? params[:duration_s].to_i : 30
Kernel.sleep duration_s
render text: "OK", content_type: 'text/plain'
end
end
......@@ -82,6 +82,8 @@ Rails.application.routes.draw do
draw :operations
draw :instance_statistics
get '/chaos/sleep' => 'chaos#sleep'
end
draw :api
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment