From f304492716e46858172ba5df85849a22a7859d1a Mon Sep 17 00:00:00 2001 From: AdySec <133128400+adysec@users.noreply.github.com> Date: Fri, 28 Mar 2025 11:37:53 +0800 Subject: [PATCH] Fix: binlog_expire_logs_seconds (#6626) This PR updates the MySQL container configuration by setting the parameter --binlog_expire_logs_seconds to 604800 seconds (7 days). This change ensures that MySQL automatically purges binary logs older than 7 days, helping to conserve disk space and maintain precise log management. ### What problem does this PR solve? _Briefly describe what this PR aims to solve. Include background context that will help reviewers understand the purpose of the PR._ ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) - [ ] New Feature (non-breaking change which adds functionality) - [ ] Documentation Update - [ ] Refactoring - [ ] Performance Improvement - [ ] Other (please describe): --- docker/docker-compose-base.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/docker/docker-compose-base.yml b/docker/docker-compose-base.yml index 93804d5a9..d9a39fdfc 100644 --- a/docker/docker-compose-base.yml +++ b/docker/docker-compose-base.yml @@ -81,6 +81,7 @@ services: --default-authentication-plugin=mysql_native_password --tls_version="TLSv1.2,TLSv1.3" --init-file /data/application/init.sql + --binlog_expire_logs_seconds=604800 ports: - ${MYSQL_PORT}:3306 volumes: