nextcloud / nextcloud/helm

Log rotation in multi replica environment

Open
#822 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go Template
Stars
534
Forks
314
Avg merge
42m
Merged PRs (30d)
1

Description

Describe your Issue

I have NC deployed in 2 replicas, each replica has it's own ephemeral storage for logs.

`logfile` => `/tmp/nextcloud`,
'log_rotate_size' => 10485760,
'logfile_audit' => '/tmp/audit.log'

I faced the problem that CronJob can't do log rotation, because it doesn't have access to each ephemeral storage.

My plan B is to write logs from each replica into common PVC, but then I can't differentiate logs from replicas, it doesn't have field like host / hostname.

Any ideas ?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is identified. Start by locating the chart configuration and templates for logfile, log_rotate_size, and logfile_audit, then determine how multi-replica logging and replica identification should work; done means rotation works without per-replica CronJob access and logs remain distinguishable.

Written by the indexing model from the issue text.

Assessment

Tech stack
helm, kubernetes
Domain
devops, infrastructure
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.