Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Report FQDN on host.name as opt-in, enabled by feature flag (#2218)
* wip * wip * wip * clean up * wip * . * agent.name as fqdn * it works * wip * WIP - using fake input, created test, it seems to work * finish test for feature flags * remove debug log * some clean up * mage check * fixing licenses * it works * it works * remove debug logs and comments * make notice * fake component and shipper are built by TestMain * fixing tests * make notice * adjust tests * update elatic-agent-client * add .exe for win binaries * adjust fake components build * increase test timeout * fix tests * adjust features pkg and don't send featuresFlag if nil * it works * make notice * revert some changes * handle error properly * add TODO * Set FQDN for Vagrant elastic-agent VM Useful for testing FQDN feature; harmless otherwise * Undoing trivial formatting changes * Running mage fmt * Remove personal repo from NOTICE overrides * Sorting imports * Fix error handling * Fixing access * Fixing packaging of fake component * Update logging * Refactoring fake component * Allowing fmt.Print* in TestMain * Remove redundant return * Fixing typo in error message * Undo unintentional changes * Removing redundant TestMain file * Add comment on FQDN to Vagrantfile * Remove debug logging statements * Making test pass * Document feature flags configuration in reference config file * Adding CHANGELOG entry * Use convenience method * Formatting * Use convenience method from elastic-agent-libs * Running mage update * Fixing imports * Reducing whitespace changes * Reducing whitespace changes * Reducing whitespace changes * Reducing whitespace changes * Restore timeout duration * Move mutex inside struct * Prevent mutex copying * Fixing state diagnostics test * Fixing components diagnostics test * Adding features.source to components golden file * More interesting diagnostics state test * Log error if FQDN lookup fails and fallback to OS-reported hostname * Bump up go-sysinfo dependency version * Fix typos * Fixing compile errors * Fix tests * Fix imports * Fix issues lost in rebase * Fixing more imports * Updating NOTICE.txt * Clarify features indentation * Remove replace directive * Bumping up version on elastic-agent-client dependency * Adding test mocking DNS * Initialize featuresIdx in same place as units' configIdx * Updating NOTICE.txt * Remove unnecessary nil check * Set features in state initially * Update features in state from checkin observed message * Remove TODO * Updating elatic-agent.yml test fixture to enable FQDN feature flag * Try flipping the authoritative flag * Remove unreliable DNS mocking test * Set source * Update test fixture * Change logger * Fixing test case * Omit feature flags serialization from state.yaml diag file * Updating NOTICE.txt * Add descriptive comment on why Features is not being serialized as YAML * Updating test fixture * Inject logger into metadata methods --------- Co-authored-by: Shaunak Kashyap <ycombinator@gmail.com> (cherry picked from commit be818cc)
- Loading branch information