summaryrefslogtreecommitdiff
path: root/puppet/modules/site_apache/manifests/common/autorestart.pp
blob: 0273f272f812c8b97ee0d6b424f129e3b35435e8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#
# Adds autorestart extension to apache on crash
#
class site_apache::common::autorestart {

  file { '/etc/systemd/system/apache2.service.d':
    ensure => directory,
    mode   => '0755',
  }

  ::systemd::unit_file { 'apache2.service.d/autorestart.conf':
    source  => 'puppet:///modules/site_apache/autorestart.conf',
    require => [
      File['/etc/systemd/system/apache2.service.d'],
      Service['apache'],
    ]
  }
}