Conversation
I don't know what this means please. Could you dumb it down for me? 🙏 |
|
@curusarn apologies for opaque language 🙏 I mean: we already have $HOSTNAME set in install scripts on all-ish platforms. Rather than overriding user's choice by e.g. always reading /etc/hostname, I wanted a strong positive signal the user wants the hostname overridden at runtime. In this case, explicitly creating a file means: "I know what I'm doing and I want this overridden". |
|
This allows us to override ENV HOSTNAME by writing /var/lib/better-stack/hostname.txt. When do we plan to write into /var/lib/better-stack/hostname.txt please? Does the customer need to write the hostname? |
We don't, because for most use-cases setting HOSTNAME at install-time is sufficient. I'm imagining the file would be created e.g. in an instance setup script. That's why I wanted the action needed to be blazing-fast and one-time. Hence my point about adding it to the docs. It'd be part of Advanced configuration. |
Why don't we read /etc/hostname anytime HOSTNAME env is unset?
I'm not excited to see a custom file introduced for something as simple as setting hostname. 🙏 |
Would it be ever? Or are you thinking that it should be overridden if e.g. explicitly set to an empty string? Probably would need The more mounts/more privileges slightly scared me off going that route :) But if you feel strongly that's the way to go, I'll do that 🙏 |
|
@curusarn adjusted to use |
Thanks! 🙏 ChatGPT claims Datadog get hostname from docker socket via I'm fine with |
True, but we also don't ship |
|
Thanks! "uts: host" seems fine & simple. We can always adjust later. 🙏 |
should be enough to:
and (re)starting containers