files/aerobase-cookbooks/aerobase/libraries/unifiedpush.rb
# guards against creating secrets on non-bootstrap node
guards against creating secrets on non-bootstrap node
guards against creating secrets on non - bootstrap node
def parse_nginx_listen_ports
      [
        [%w{nginx listen_port}, %w{global access_port}]
      ].each do |left, right|
        if !Unifiedpush[left.first][left.last].nil?
          next
        end
        default_set_access_port = node['unifiedpush'][right.first.gsub('_', '-')][right.last]
        user_set_access_port = Unifiedpush[right.first][right.last]
        Unifiedpush[left.first][left.last] = user_set_access_port || default_set_access_port
      end
    end
def parse_nginx_listen_ports [ [ %w{ nginx listen_port } , %w{ global access_port } ] ] . each do | left , right | if ! Unifiedpush [ left . first ] [ left . last ] . nil? next end default_set_access_port = node [ 'unifiedpush' ] [ right . first . gsub ( '_' , '-' ) ] [ right . last ] user_set_access_port = Unifiedpush [ right . first ] [ right . last ] Unifiedpush [ left . first ] [ left . last ] = user_set_access_port || default_set_access_port end end
guards against creating secrets on non-bootstrap node
guards against creating secrets on non - bootstrap node