Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support of IOT agent flavor #717

Merged
merged 5 commits into from
May 29, 2020
Merged

Conversation

kbogtob
Copy link
Contributor

@kbogtob kbogtob commented May 26, 2020

What does this PR do?

It adds the base logic to support agent flavors. And it adds the support of the IOT agent.

Motivation

Allowing users to install specific flavors of the agent.

@kbogtob kbogtob requested a review from a team as a code owner May 26, 2020 13:56
Copy link
Member

@mx-psi mx-psi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (but I don't know Chef so maybe someone else should look at it too). Left a small nit.

@@ -40,6 +40,8 @@
# Example:
# default['datadog']['agent_version'] = '7.16.0'
default['datadog']['agent_version'] = nil # nil to install latest
# Agent flavor, acceptable values are "agent", iot-agent"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: on the Agent we use agent and iot_agent for the flavors, maybe we could use those values here too for consistency? I am not sure if the other ones are user-facing though, but just in case they ever are.

Copy link
Contributor

@albertvaka albertvaka May 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like iot-agent better because it matches the name of the package (datadog-iot-agent). The flavor names in the Agent code are to identify them on our side, but shouldn't be user-facing.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks Albert

Copy link
Contributor

@albertvaka albertvaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want to document the new field in the README.

attributes/default.rb Outdated Show resolved Hide resolved
attributes/default.rb Outdated Show resolved Hide resolved
@KSerrania
Copy link
Contributor

Would it be easier to set agent_flavor to the package name (ie. datadog-agent / datadog-iot-agent instead of agent / iot-agent)? It would also make it behave the same way the install script does: https://github.com/DataDog/datadog-agent/blob/669abd39dae58460e3cc680c3af5a83bb763311d/cmd/agent/install_script.sh#L102-L105

@albertvaka
Copy link
Contributor

+1 to Kylian, it will also ease adding support for flavors that don't start with "datadog-" like dogstatsd.

@kbogtob kbogtob requested a review from a team as a code owner May 28, 2020 14:08
Copy link
Contributor

@albertvaka albertvaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@kbogtob kbogtob merged commit 8363e6e into master May 29, 2020
@kbogtob kbogtob deleted the kbogtob/support-iot-agent-flavor branch May 29, 2020 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants