atomic-podman: Set log imit to 50m

By default podman containers can write unlimited bytes
of log and evenrually fill up the disk nodes.

Set the max size per containers to 50MB.

story: 2007402
task: 39003
Change-Id: I405e331eb1f9f987d3fbc301a09ab25bcb96926d
Signed-off-by: Spyros Trigazis <spyridon.trigazis@cern.ch>
This commit is contained in:
Spyros Trigazis 2020-03-10 18:13:33 +01:00 committed by Spyros Trigazis
parent 9d543960d2
commit 2d2bd5d710
1 changed files with 6 additions and 0 deletions

View File

@ -55,6 +55,12 @@ systemctl restart sshd
_prefix="${CONTAINER_INFRA_PREFIX:-docker.io/openstackmagnum/}"
if [ "$(echo $USE_PODMAN | tr '[:upper:]' '[:lower:]')" == "true" ]; then
cat > /etc/containers/libpod.conf <<EOF
# Maximum size of log files (in bytes)
# -1 is unlimited
# 50m
max_log_size = 52428800
EOF
cat > /etc/systemd/system/heat-container-agent.service <<EOF
[Unit]
Description=Run heat-container-agent