Class: Orchestration::DockerHealthcheck
- Inherits:
-
Object
- Object
- Orchestration::DockerHealthcheck
- Defined in:
- lib/orchestration/docker_healthcheck.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.execute ⇒ Object
6 7 8 |
# File 'lib/orchestration/docker_healthcheck.rb', line 6 def self.execute new.execute end |
Instance Method Details
#execute ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/orchestration/docker_healthcheck.rb', line 10 def execute return_code = 1 # rubocop:disable Lint/RescueException begin response = run return_code = 0 if success?(response.code) puts (response.code) rescue Exception => e puts "[#{__FILE__}] ERROR: #{e.inspect}" ensure exit return_code end # rubocop:enable Lint/RescueException end |