From 59d2ae598bff0ef919cb4d19d47c6cbee8da12c6 Mon Sep 17 00:00:00 2001 From: Vedran Pavic Date: Sat, 24 Oct 2015 01:44:34 +0200 Subject: [PATCH] Update documentation to clarify systemd service user Closes gh-4293 --- spring-boot-docs/src/main/asciidoc/deployment.adoc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spring-boot-docs/src/main/asciidoc/deployment.adoc b/spring-boot-docs/src/main/asciidoc/deployment.adoc index 96a1ee2091f..a08bc1d30a9 100644 --- a/spring-boot-docs/src/main/asciidoc/deployment.adoc +++ b/spring-boot-docs/src/main/asciidoc/deployment.adoc @@ -385,8 +385,8 @@ Systemd is the successor to `init.d` scripts, and now being used by many many mo distributions. Although you can continue to use `init.d` script with `systemd`, it is also possible to launch Spring Boot applications using `systemd` '`service`' scripts. -For example, to run a Spring Boot application installed in `var/myapp` you can add the -following script in `/etc/systemd/system/myapp.service`: +For example, to run a Spring Boot application installed in `var/myapp` as user `myapp` you +can add the following script in `/etc/systemd/system/myapp.service`: [indent=0] ---- @@ -395,6 +395,7 @@ following script in `/etc/systemd/system/myapp.service`: After=syslog.target [Service] + User=myapp ExecStart=/var/myapp/myapp.jar [Install]