Skip to content

Commit

Permalink
Keep rolled logs in log dir
Browse files Browse the repository at this point in the history
Otherwise, they are written to the cwd, wich is the app user on the
server.
  • Loading branch information
tobias committed Aug 10, 2024
1 parent 978eeab commit 2df51fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions resources/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<file>${log.dir:-logs}/clojars.ednl</file>
<!-- Handling rotation here instead of via logrotate in the server config to avoid restarting the process -->
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>clojars-%d{yyyy-MM-dd}.%i.ednl.gz</fileNamePattern>
<fileNamePattern>${log.dir:-logs}/clojars-%d{yyyy-MM-dd}.%i.ednl.gz</fileNamePattern>
<maxFileSize>64MB</maxFileSize>
<maxHistory>14</maxHistory>
<totalSizeCap>512GB</totalSizeCap>
Expand All @@ -18,7 +18,7 @@
<file>${log.dir:-logs}/clojars.log</file>
<!-- Handling rotation here instead of via logrotate in the server config to avoid restarting the process -->
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>clojars-%d{yyyy-MM-dd}.%i.log.gz</fileNamePattern>
<fileNamePattern>${log.dir:-logs}/clojars-%d{yyyy-MM-dd}.%i.log.gz</fileNamePattern>
<maxFileSize>64MB</maxFileSize>
<maxHistory>14</maxHistory>
<totalSizeCap>512GB</totalSizeCap>
Expand Down

0 comments on commit 2df51fb

Please sign in to comment.