components/ruby/puppet/patches/puppet-14-log-smf.patch
changeset 7651 70c0daa6928d
parent 7565 48aa82a0931f
equal deleted inserted replaced
7650:2e39c59b83f8 7651:70c0daa6928d
    18    # undefs other objects.
    18    # undefs other objects.
    19    def Log.close(destination)
    19    def Log.close(destination)
    20 +    if Puppet[:degrade_smf_on_error]
    20 +    if Puppet[:degrade_smf_on_error]
    21 +      if !@degraded
    21 +      if !@degraded
    22 +        if Puppet.run_mode.agent?
    22 +        if Puppet.run_mode.agent?
    23 +          system 'svcadm clear puppet:agent'
    23 +          system 'svcadm clear puppet:agent > /dev/null 2>&1'
    24 +        elsif Puppet.run_mode.master?
    24 +        elsif Puppet.run_mode.master?
    25 +          system 'svcadm clear puppet:master'
    25 +          system 'svcadm clear puppet:master > /dev/null 2>&1'
    26 +        end
    26 +        end
    27 +      end
    27 +      end
    28 +    end
    28 +    end
    29 +
    29 +
    30      if @destinations.include?(destination)
    30      if @destinations.include?(destination)