Skip to content

Commit

Permalink
action based on if there is any ale sensor
Browse files Browse the repository at this point in the history
  • Loading branch information
ljblancoredborder committed Aug 5, 2024
1 parent 2bda259 commit bbaff20
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions resources/recipes/configure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,9 @@

# TODO: replace node['redborder']['services'] in action with 'proxy_services'..
rbale_config 'Configure redborder-ale' do
ale_nodes node.run_state['sensors_info_all']['ale-sensor']
if node['redborder']['services']['redborder-ale']
ale_sensors = node.run_state['sensors_info_all']['ale-sensor']
if !ale_sensors.empty?
ale_nodes ale_sensors
action [:add]
else
action [:remove]
Expand Down

0 comments on commit bbaff20

Please sign in to comment.