Netdata: Parameters for headless install

Created on 12 May 2018  路  3Comments  路  Source: netdata/netdata

The already awesome oneline install process is great for the default use case.
I think it could be improved for the "headless collector" use case.

The install would need two new parameters:

  • --api-key= its value will be [stream].api key in stream.conf
  • --my-head-is= goes to [stream].destination in stream.conf

If none of them are given, then do the default install.
If only one of them are given, then error and show Usage help
If both parameters are given,
then additionally set [stream].enabled = yes in stream.conf
and [global].memory mode = none and [web].mode = none in `netdata.conf'

Pros: one line headless collector install
Cons: more complicated install script

What do you think, is it worth to implement this?

discussion

Most helpful comment

I think you can easily achieve this yourself:

bash <(curl -Ss https://my-netdata.io/kickstart.sh) --dont-wait --dont-start-it

cat >/etc/netdata/netdata.conf <<EOF
[global]
  memory mode = none
[web]
  mode = none
EOF

cat >/etc/netdata/stream.conf <<EOF
[stream]
  enabled = yes
  destination = master-netdata
  api key = API KEY
EOF

systemctl start netdata

Simple?

All 3 comments

I think you can easily achieve this yourself:

bash <(curl -Ss https://my-netdata.io/kickstart.sh) --dont-wait --dont-start-it

cat >/etc/netdata/netdata.conf <<EOF
[global]
  memory mode = none
[web]
  mode = none
EOF

cat >/etc/netdata/stream.conf <<EOF
[stream]
  enabled = yes
  destination = master-netdata
  api key = API KEY
EOF

systemctl start netdata

Simple?

This is simple to accomplish by a small script (ex. one posted by @ktsaou) and it also introduces more complexity to the installer. I think it is better to focus on the core monitoring application not on the installer which is added to it.

@ktsaou so the config files can contain only the changed settings because all others are default? This makes the things easier. I think I can use this idea, thanks.

Was this page helpful?
0 / 5 - 0 ratings