Skip to content

Commit

Permalink
Add configure_journald
Browse files Browse the repository at this point in the history
  • Loading branch information
manegron committed Dec 12, 2023
1 parent bd0bf1b commit acd2fd8
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 1 deletion.
22 changes: 22 additions & 0 deletions resources/recipes/configure_journald.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#
# Cookbook Name:: manager
# Recipe:: configure_journald
#
# Copyright 2024, redborder
#
# AFFERO GENERAL PUBLIC LICENSE V3
#

template "/etc/systemd/journald.conf" do
source "journald.conf.erb"
owner "root"
group "root"
mode 0440
retries 2
notifies :restart, 'service[systemd-journald]', :delayed
end

service 'systemd-journald' do
supports :status => true, :start => true, :restart => true, :reload => true
action :nothing
end
2 changes: 1 addition & 1 deletion resources/recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
include_recipe 'rb-manager::prepare_system'
include_recipe 'rb-manager::configure'
include_recipe 'rb-manager::configure_cron_tasks'

include_recipe 'rb-manager::configure_journald'
49 changes: 49 additions & 0 deletions resources/templates/default/journald.conf.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# This file was generated by CHEF (redborder)
#
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it under the
# terms of the GNU Lesser General Public License as published by the Free
# Software Foundation; either version 2.1 of the License, or (at your option)
# any later version.
#
# Entries in this file show the compile time defaults. Local configuration
# should be created by either modifying this file, or by creating "drop-ins" in
# the journald.conf.d/ subdirectory. The latter is generally recommended.
# Defaults can be restored by simply deleting this file and all drop-ins.
#
# Use 'systemd-analyze cat-config systemd/journald.conf' to display the full config.
#
# See journald.conf(5) for details.

[Journal]
Storage=volatile
#Compress=yes
#Seal=yes
#SplitMode=uid
#SyncIntervalSec=5m
RateLimitIntervalSec=1s
RateLimitBurst=300
SystemMaxUse=100M
SystemKeepFree=100M
SystemMaxFileSize=50M
#SystemMaxFiles=100
RuntimeMaxUse=50M
#RuntimeKeepFree=
#RuntimeMaxFileSize=
#RuntimeMaxFiles=100
#MaxRetentionSec=
#MaxFileSec=1month
#ForwardToSyslog=no
#ForwardToKMsg=no
#ForwardToConsole=no
#ForwardToWall=yes
#TTYPath=/dev/console
#MaxLevelStore=debug
#MaxLevelSyslog=debug
#MaxLevelKMsg=notice
#MaxLevelConsole=info
#MaxLevelWall=emerg
#LineMax=48K
#ReadKMsg=yes
Audit=

0 comments on commit acd2fd8

Please sign in to comment.