Uploaded image for project: 'Modules'
  1. Modules
  2. MODULES-10941

apache: Wrong handling of "error_log => 'syslog'"

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: apache
    • Labels:
      None
    • Environment:

      Debian/Ubuntu Linux

    • Template:
      MODULES Bug Template
    • Acceptance Criteria:
      Hide

      ErrorLog can be configured as documented in the Apache documentation.

      Show
      ErrorLog can be configured as documented in the Apache documentation.
    • Method Found:
      Needs Assessment
    • QA Risk Assessment:
      Needs Assessment

      Description

      Basic Info
      Module Version: 5.8.0
      Puppet Version: 6.20.0
      OS Name/Version: Debian 10 / Ubuntu 20.04

      When explicitely configuring the apache resource to set "ErrorLog syslog" in the main config file, using

      class { 'apache':
        default_vhost => false,
        error_log     => syslog,
      }
      

      the resulting /etc/apache2/apache2.conf file contains the line

      ErrorLog "/var/log/apache2/syslog"

      Note: It doesn't make a difference if I write "syslog" instead of just syslog.

      In addition, when using

      apache::vhost { 'myvhost':
        access_log            => true,
        access_log_pipe       => '|/usr/bin/logger -t apache2',
        error_log             => true,
        error_log_syslog      => syslog,
        ...,
      }

      The resulting VHost file contains

      ErrorLog "syslog"
      CustomLog "|/usr/bin/logger -t apache2" combined

      CustomLog doesn't understand the syslog keyword, so I need to pipe to /usr/bin/logger to get the same effect. As a workaround, using "|/usr/bin/logger ..." also for error_log works as expected.

      Desired Behavior:

      Write correct ErrorLog directives in case of syslog, according to the Apache documentation. Thus, the lines should look like this:

      ErrorLog syslog 

      Actual Behavior:

      See above.

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            dhs@recommind.com Dirk Heinrichs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:

                Zendesk Support