Skip to content

Commit 236bf09

Browse files
authored
FEATURE: Expose close on runner instance (#346)
1 parent 899d650 commit 236bf09

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

lib/prometheus_exporter/server/runner.rb

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def start
5050
)
5151
end
5252

53-
server =
53+
@server =
5454
server_class.new(
5555
port: port,
5656
bind: bind,
@@ -60,7 +60,11 @@ def start
6060
auth: auth,
6161
realm: realm,
6262
)
63-
server.start
63+
@server.start
64+
end
65+
66+
def stop
67+
@server.stop
6468
end
6569

6670
attr_accessor :unicorn_listen_address, :unicorn_pid_file

0 commit comments

Comments
 (0)