Skip to content

Commit

Permalink
(!site/cp) set docker::log_opt log size limits
Browse files Browse the repository at this point in the history
  • Loading branch information
jhoblitt committed May 23, 2023
1 parent e07eace commit 83867dd
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
6 changes: 5 additions & 1 deletion hieradata/common.yaml
Expand Up @@ -225,7 +225,11 @@ accounts::user_list:
<<: *rm_user
hreinking_b:
<<: *rm_user

docker::log_driver: "json-file"
docker::log_opt:
- "max-file=2"
- "max-size=50m"
- "mode=non-blocking"
tuned::profile: "latency-performance"
selinux::mode: "disabled"
# Stop iptables by default - the default rules are highly restrictive to the
Expand Down
2 changes: 2 additions & 0 deletions hieradata/site/cp.yaml
@@ -1,4 +1,6 @@
---
docker::log_driver: ~
docker::log_opt: ~
easy_ipa::ipa_master_fqdn: "ipa1.cp.lsst.org"
# sssd ipa client setup -- do not use on ipa servers
sssd::domains:
Expand Down
16 changes: 16 additions & 0 deletions spec/spec_helper.rb
Expand Up @@ -498,6 +498,22 @@ def node_files
version: '2.17.3',
)
end

it do
# skip this example for class tests
next unless defined?(node_params)

to = node_params[:site] == 'cp' ? 'not_to' : 'to'

is_expected.send(to, contain_class('docker').with(
log_driver: 'json-file',
log_opt: %w[
max-file=2
max-size=50m
mode=non-blocking
],
))
end
end

shared_examples 'rke profile' do
Expand Down

0 comments on commit 83867dd

Please sign in to comment.