X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/e2d9c76e0d9a32f82f45b7a3d98199eb18405351..a0858dce1ce11c24de0103a341bc0ea8f75154ea:/cookbooks/systemd/templates/default/service.erb diff --git a/cookbooks/systemd/templates/default/service.erb b/cookbooks/systemd/templates/default/service.erb index 13983b02b..57f6a61e7 100644 --- a/cookbooks/systemd/templates/default/service.erb +++ b/cookbooks/systemd/templates/default/service.erb @@ -1,3 +1,5 @@ +# DO NOT EDIT - This file is being maintained by Chef + [Unit] Description=<%= @description %> <% if @after -%> @@ -15,6 +17,12 @@ Environment="<%= name %>=<%= value %>" <% if @environment_file -%> EnvironmentFile=<%= @environment_file %> <% end -%> +<% if @user -%> +User=<%= @user %> +<% end -%> +<% if @group -%> +Group=<%= @group %> +<% end -%> <% if @exec_start_pre -%> ExecStartPre=<%= @exec_start_pre %> <% end -%> @@ -34,6 +42,9 @@ Restart=<%= @restart %> <% if @timeout_sec -%> TimeoutSec=<%= @timeout_sec %> <% end -%> +<% if @pid_file -%> +PIDFile=<%= @pid_file %> +<% end -%> [Install] WantedBy=multi-user.target