Log Rotation for Bitbucket Cloud Self-Hosted Runners

Gajesh Bhat
Contributor
May 31, 2024

Are logs for Bitbucket Cloud's self-hosted runners automatically rotated? If not, Can anyone provide some guidance on setting up log rotation for these logs across different operating systems (Linux, Windows, and Mac).  Specifically:

  • Linux: I have experience using logrotate on Linux. Are there any additional recommendations or best practices for runner logs generated by Bitbucket Runners (For example, the frequency of rotation and how many backups to store.)?
  • Windows: What are the best methods or tools for setting up log rotation?
  • Mac: What are the recommended practices for managing log rotation on macOS?

Note: I am not referring to Docker-based Linux Runners, as those logs are managed using a Kubernetes Runner Autoscaler setup I have provisioned using the instructions here: Autoscaler for Runners on Kubernetes

Any suggestions or instructions would be greatly appreciated. Thank you!

1 answer

1 accepted

1 vote
Answer accepted
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 3, 2024

Hi Gajesh,

The default configuration should delete old log files after 7 days. If you want to change that, you can check our guide below for configuring logging in self-hosted runners:

Kind regards,
Theodora

Gajesh Bhat
Contributor
June 3, 2024

Thank you Theodora. :) That's what I was looking for.

Like Theodora Boudale likes this
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 4, 2024

You are very welcome, Gajesh! Please feel free to reach out if you ever need anything else!

Like Gajesh Bhat likes this
Om Joshi June 17, 2024

Anyone has implemented logrotate on DC with redhat logrotate? 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events