autoscaler icon indicating copy to clipboard operation
autoscaler copied to clipboard

Add the ability to configure agent logging

Open mach6 opened this issue 3 years ago • 5 comments

Adds the ability to specify the logging driver and options for the runner (agent), gc, and watchtower containers.

Example config;

DRONE_AGENT_LOGGING_DRIVER=json-file
DRONE_AGENT_LOGGING_OPTIONS=max-size:100m,max-file:5

ref: https://docs.docker.com/config/containers/logging/configure/#supported-logging-drivers

mach6 avatar Jan 29 '21 01:01 mach6

@bradrydzewski @tboerger Any feedback on this one? Cheers.

mach6 avatar Feb 04 '21 19:02 mach6

Why don't you just define the logging driver on Docker daemon level? IMHO it doesn't make sense to define that per container.

tboerger avatar Feb 09 '21 13:02 tboerger

Why don't you just define the logging driver on Docker daemon level? IMHO it doesn't make sense to define that per container.

While one can certainly do this; the intent with the per container config options is to enable finer configuration. for example; If one does not want the drone-gc or watchtower logging behavior to be the same as the agent. Maybe one wants the agent logs to leverage the gcplogs driver and drone-gc to leverage json-file, for example.

Also, setting the behavior at the daemon level impacts the logging behavior of the containers which support pipeline steps.

mach6 avatar Feb 10 '21 06:02 mach6

@tboerger @bradrydzewski any additional thoughts on this one?

mach6 avatar Jun 14 '21 18:06 mach6

PR re-based against v1.8.1 and force-pushed

mach6 avatar Apr 20 '22 00:04 mach6