Saltstack Official Apache Formula
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

54 lines
1.9KB

  1. # Managed by saltstack
  2. # envvars - default environment variables for apache2ctl
  3. # this won't be correct after changing uid
  4. unset HOME
  5. # for supporting multiple apache2 instances
  6. if [ "${APACHE_CONFDIR##/etc/apache2-}" != "${APACHE_CONFDIR}" ] ; then
  7. SUFFIX="-${APACHE_CONFDIR##/etc/apache2-}"
  8. else
  9. SUFFIX=
  10. fi
  11. # Since there is no sane way to get the parsed apache2 config in scripts, some
  12. # settings are defined via environment variables and then used in apache2ctl,
  13. # /etc/init.d/apache2, /etc/logrotate.d/apache2, etc.
  14. export APACHE_RUN_USER={{ salt['pillar.get']('apache:user', 'www-data') }}
  15. export APACHE_RUN_GROUP={{ salt['pillar.get']('apache:group', 'www-data') }}
  16. # temporary state file location. This might be changed to /run in Wheezy+1
  17. export APACHE_PID_FILE=/var/run/apache2/apache2$SUFFIX.pid
  18. export APACHE_RUN_DIR=/var/run/apache2$SUFFIX
  19. export APACHE_LOCK_DIR=/var/lock/apache2$SUFFIX
  20. # Only /var/log/apache2 is handled by /etc/logrotate.d/apache2.
  21. export APACHE_LOG_DIR=/var/log/apache2$SUFFIX
  22. ## The locale used by some modules like mod_dav
  23. export LANG=C
  24. ## Uncomment the following line to use the system default locale instead:
  25. #. /etc/default/locale
  26. export LANG
  27. ## The command to get the status for 'apache2ctl status'.
  28. ## Some packages providing 'www-browser' need '--dump' instead of '-dump'.
  29. #export APACHE_LYNX='www-browser -dump'
  30. ## If you need a higher file descriptor limit, uncomment and adjust the
  31. ## following line (default is 8192):
  32. #APACHE_ULIMIT_MAX_FILES='ulimit -n 65536'
  33. ## If you would like to pass arguments to the web server, add them below
  34. ## to the APACHE_ARGUMENTS environment.
  35. #export APACHE_ARGUMENTS=''
  36. ## Enable the debug mode for maintainer scripts.
  37. ## This will produce a verbose output on package installations of web server modules and web application
  38. ## installations which interact with Apache
  39. #export APACHE2_MAINTSCRIPT_DEBUG=1
  40. {%- for envvar in salt['pillar.get']('apache:envvars', []) %}
  41. {{ envvar }}
  42. {%- endfor %}