# Do not forget to add new drop logs to yandex-hbf-agent/logs_recreation_workaround.sls
# (salt will recreate them when absent, see RUNTIMECLOUD-7560)

/var/log/yandex-hbf-agent/Y_FW_drop.log
/var/log/yandex-hbf-agent/Y_FW_OUT_drop.log
/var/log/yandex-hbf-agent/Y_END_OUT_INET_drop.log
/var/log/yandex-hbf-agent/PREROUTING_MTN_NAT.log
/var/log/yandex-hbf-agent/OUTPUT_MTN_NAT.log
{
  rotate 12
  size 10M
  notifempty
  missingok
  compress
  delaycompress
  create syslog adm
  postrotate
    /bin/kill -HUP `cat /var/run/rsyslogd.pid` 2> /dev/null || true
  endscript
}

/var/log/yandex-hbf-agent/yandex-hbf-agent.log
{
  rotate 14
  size 100M
  notifempty
  missingok
  compress
  delaycompress
  su hbf hbf
  postrotate
    pid=$(portoctl get yandex-hbf-agent root_pid)
    kill -HUP -$pid
  endscript
}
