store alloy logs agent position file on hostpath - #659
Conversation
|
Hmm, thoughts on doing it via hostPath instead? The data is only relevant to the node the pod is on, if it's a different node it's different logs, thus attaching a pvc with a WAL/positions from a different node doesn't make sense since it can't access those logs. With the hostPath the WAL/positions are stored with the node the logs are on anyway and we avoid creating pvcs/pvs. |
If possible I think this could make a lot of sense. |
it makes sense for me as well. I will try to use the hostpath instead |
SEQUOIIA
left a comment
There was a problem hiding this comment.
for using hostPath instead. The suggested path is the one that currently has the migrated WAL/position data in production.
This pull request updates the Alloy logs DaemonSet configuration to use a persistent storage path and mounts for log data, improving data durability and aligning with best practices for stateful components. The changes ensure that Alloy's log storage is backed by a hostPath volume at
/srv/alloy/datainstead of the previous ephemeral/tmp/alloypath.Persistent storage improvements:
/tmp/alloyto/srv/alloy/datain the DaemonSet arguments for more durable log data storage./srv/alloy/datausing thealloy-storage-logsvolume in the container spec.hostPathvolume namedalloy-storage-logsat/srv/alloy/datawith typeDirectoryOrCreateto ensure the directory exists on the host.Helm release configuration updates:
release.yamlto addstoragePathand mount definitions for/srv/alloy/data, and included the correspondinghostPathvolume undervolumes.extra.