Skip to content

Instantly share code, notes, and snippets.

@joelhandwell
Created March 18, 2017 02:50
Show Gist options
  • Save joelhandwell/f250422f5680630b4569ef66019b2a8b to your computer and use it in GitHub Desktop.
Save joelhandwell/f250422f5680630b4569ef66019b2a8b to your computer and use it in GitHub Desktop.
php7.1 systemd unit config chef resources
file '/lib/systemd/system/php7.1-fpm.service' do
content <<-FILE
[Unit]
Description=The PHP FastCGI Process Manager
After=network.target
[Service]
Type=simple
PIDFile=/usr/local/var/run/php-fpm.pid
ExecStart=/usr/local/sbin/php-fpm --nodaemonize --fpm-config /usr/local/etc/php-fpm.conf
ExecReload=/bin/kill -USR2 $MAINPID
PrivateTmp=true
[Install]
WantedBy=multi-user.target
FILE
mode 0644
end
link '/etc/systemd/system/multi-user.target.wants/php7.1-fpm.service' do
to '/lib/systemd/system/php7.1-fpm.service'
mode 0777
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment