Skip to content

Commit

Permalink
Update LocalRunGuide.md
Browse files Browse the repository at this point in the history
Improved optional service section regarding environment variables in a separate .env file
  • Loading branch information
manuelkamp authored Dec 27, 2023
1 parent 9cb8c9f commit 54859ac
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions LocalRunGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,12 @@ Note: Currently the app will run in the background until manually closed.

### Optional: Run Stirling-PDF as a service

First create a .env file, where you can store environment variables:
```
touch /opt/Stirling-PDF/.env
```
In this file you can add all variables, one variable per line, as stated in the main readme (for example SYSTEM_DEFAULTLOCALE="de-DE").

Create a new file where we store our service settings and open it with nano editor:
```
nano /etc/systemd/system/stirlingpdf.service
Expand All @@ -223,6 +229,7 @@ Group=root
Type=simple
EnvironmentFile=/opt/Stirling-PDF/.env
WorkingDirectory=/opt/Stirling-PDF
ExecStart=/usr/bin/java -jar Stirling-PDF-0.17.2.jar
ExecStop=/bin/kill -15 $MAINPID
Expand Down

0 comments on commit 54859ac

Please sign in to comment.