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 Fleet Server docs #585

Merged
merged 9 commits into from
Apr 30, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@

[[elastic-agent-cmd-options]]
[role="xpack"]
= {agent} command line options

++++
<titleabbrev>Command line options</titleabbrev>
++++
= Command reference

beta[]

{agent} provides commands for running the agent and doing common tasks:
{agent} provides commands for running the agent, managing {fleet-server}, and
doing common tasks:

//TODO: Add Fleet-related commands

* <<elastic-agent-enroll-command,enroll>>
* <<elastic-agent-help-command,help>>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[[elastic-agent-installation-configuration]]
[role="xpack"]

= Manage your {agent}s
= {agent}s

beta[]

Expand All @@ -20,7 +20,6 @@ To learn how to install, configure, and run your {agent}s, see:
* <<start-elastic-agent>>
* <<stop-elastic-agent>>
* <<unenroll-elastic-agent>>
* <<elastic-agent-cmd-options>>
* <<elastic-agent-configuration>>
* <<dynamic-input-configuration>>

Expand All @@ -38,8 +37,6 @@ include::stop-elastic-agent.asciidoc[leveloffset=+1]

include::unenroll-elastic-agent.asciidoc[leveloffset=+1]

include::elastic-agent-command-line.asciidoc[leveloffset=+1]

include::elastic-agent-configuration.asciidoc[leveloffset=+1]

include::elastic-agent-dynamic-inputs.asciidoc[leveloffset=+1]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ image::images/kibana-fleet-policies-default-yaml.png[{fleet} showing default age
NOTE: The policy generated by {fleet} already contains the correct {es} address
and port for your setup. If you run everything locally, the address is
`127.0.0.1:9200`. If you use our
https://www.elastic.co/cloud/elasticsearch-service[hosted {ess}] on {ecloud},
{ess-product}[hosted {ess}] on {ecloud},
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
you can see the {es} endpoint URL by copying it from the overview page of your
deployment.

Expand Down
2 changes: 1 addition & 1 deletion docs/en/ingest-management/faq.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ token, which {kib} validates.
The policy generated by {fleet} already contains the correct {es} address
and port for your setup. If you run everything locally, the address is
`127.0.0.1:9200`. If you use our
https://www.elastic.co/cloud/elasticsearch-service[hosted {ess}] on {ecloud},
{ess-product}[hosted {ess}] on {ecloud},
you can copy the {es} endpoint URL from the overview page of your deployment.
If you're not running in {ecloud}, make sure the {kib} and {es} HTTPS ports
are both accessible; by default these are `5601` and `9200` respectively.
71 changes: 71 additions & 0 deletions docs/en/ingest-management/fleet/fleet-server.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
[[fleet-server]]
= {fleet-server}

beta[]

{fleet-server} is a component used to centrally manage {agent}s. It serves as a
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
control plane for updating agent policies, collecting status information, and
coordinating actions across agents.

//QUESTION: I think it's worth breaking down in detail how data flows between
// the agent, Fleet Server, Fleet, and the stack, but I might have some details
// wrong here. Is this correct?

{fleet-server} is the mechanism that connects {agent}s to {fleet} and handles
all communication between an {agent}, {fleet}, {es}, and {kib}. {fleet-server}:

* Receives status information from connected {agent}s
* Retrieves agent policies from {fleet} and stores them in {es}
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
* Ships agent policies to all connected {agent}s
* Handles communication with {es} and {kib}
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

dedemorton marked this conversation as resolved.
Show resolved Hide resolved
image:images/fleet-server-communication.png[Fleet Server handles communication between {agent}, {fleet}, {es}, and {kib}]

{fleet-server} runs as a separate service alongside {agent}. The agent uses a
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
special policy that governs how {fleet-server} connects to other systems and
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
manages agent requests. The agent typically runs as a dedicated {fleet-server},
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
but you can optionally use it for data collection on self-managed clusters. For
more details, refer to <<fleet-server-deployment>>.

[discrete]
[[fleet-server-compatibility]]
== Compatibility

{fleet-server} is compatible with the following Elastic products:

* {stack} 7.13 or later (our {ess-product}[hosted {ess}] on {ecloud} or
a self-managed cluster)
* {ece} 2.10 or later
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

{fleet-server} is supported on x64 architectures only.

[discrete]
[[add-fleet-server]]
== Add a {fleet-server}

Before using {fleet} for central management, {fleet-server} must be running. The
steps for running {fleet-server} on our {ess-product}[hosted {ess}] on {ecloud}
are different from the steps for running it on a self-managed cluster.

//TODO: Collapse this content into a tabbed widget after the steps are working.

include::{tab-widgets}/add-fleet-server/widget.asciidoc[]


Now you're ready to add {agent}s to your host systems. To learn how, see
<<add-agent-to-fleet>>.

//QUESTION: I think we probably want users to run Fleet Server as a
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
//service always, but do we want to document the scenario where users simply
//enroll the Fleet Server rather than installing it?
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

[discrete]
[[fleet-server-deployment]]
== Scale your {fleet-server} deployment

coming[a future update]

//TODO: Describe how to scale Fleet Server by adding more Fleet Servers. Also
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
//describe deployment options (like adding a load balancer)

include::{tab-widgets}/code.asciidoc[]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 6 additions & 2 deletions docs/en/ingest-management/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,24 @@ include::{docs-root}/shared/attributes.asciidoc[]

= Fleet User Guide

include::fleet-overview.asciidoc[leveloffset=+1]
include::overview.asciidoc[leveloffset=+1]

include::fleet-limitations.asciidoc[leveloffset=+1]
include::fleet/fleet-limitations.asciidoc[leveloffset=+1]

include::getting-started.asciidoc[leveloffset=+1]

include::getting-started-traces.asciidoc[leveloffset=+1]

include::fleet/fleet-server.asciidoc[leveloffset=+1]

include::elastic-agent/elastic-agent.asciidoc[leveloffset=+1]

include::agent-policies.asciidoc[leveloffset=+1]

include::data-streams.asciidoc[leveloffset=+1]

include::commands.asciidoc[leveloffset=+1]

include::troubleshooting.asciidoc[leveloffset=+1]

include::faq.asciidoc[leveloffset=+1]
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[[fleet-overview]]
[role="xpack"]
= Overview
= {fleet} and {agent} overview

beta[]

Expand All @@ -13,6 +13,8 @@ other types of data to each host. A single agent makes it easier and faster
to deploy monitoring across your infrastructure. The agent's single, unified
policy makes it easier to add integrations for new data sources.

For more information, see <<elastic-agent-installation-configuration>>.

[discrete]
[[fleet]]
== {fleet}
Expand All @@ -28,14 +30,16 @@ within seconds.
image::images/integrations.png[Integrations page]

[discrete]
[[fleet-server]]
[[fleet-server-intro]]
== {fleet-server}

{fleet-server} is the mechanism to connect {agent}s to {fleet}. It allows for
a scalable infrastructure and is supported in {ecloud} and self-managed clusters.
{fleet-server} is a separate process that communicates with the deployed {agent}s.
It can be started from any available x64 architecture {agent} artifact.

For more information, see <<fleet-server>>.

[discrete]
[[configuring-integrations]]
== {integrations} in {fleet}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
// tag::ess[]

// QUESTION: Should we add a warning here about updating to 7.13 and include a
// link to the upgrade docs?
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

{ecloud} runs a hosted version of {fleet-server}. To use {fleet-server}, start
the service:

//TODO: Describe how to start the service.
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

When you're done, log in to {kib} and go to *Management > {fleet}*. Click the
*Agents* tab to confirm that {fleet-server} is running and healthy.

//TODO: Add screen capture.

On the *Policies* tab, notice that the {agent} is enrolled in the Elastic Cloud
dedemorton marked this conversation as resolved.
Show resolved Hide resolved
policy. This policy is managed by {ecloud}. You cannot modify it.

// end::ess[]

// tag::self-managed[]

To deploy {fleet-server} on a self-managed cluster, install an {agent} and
enroll it in the default {fleet-server} policy. The policy is created
automatically when you run {fleet} for the first time.

To add {fleet-server}:

//QUESTION: Do we want to show how to call the API to generate the token, or
Copy link
Contributor

Choose a reason for hiding this comment

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

Focus on easy setup. Ideally the setup would have enough docs directly in the UI.

//walk users through the easy setup with the UI?
dedemorton marked this conversation as resolved.
Show resolved Hide resolved

. Log in to {kib} and go to *Management > {fleet}*.

. Click *Fleet settings*, and in the *Fleet Server hosts* field, specify the URL
{agent}s will use to connect to {fleet-server}. For example,
`https://1.2.3.4:8220`, where `1.2.3.4` is the host IP where you will install
{fleet-server}.

dedemorton marked this conversation as resolved.
Show resolved Hide resolved
. Save and apply the settings.

. Click the *Agents* tab and follow the in-product instructions to add a
{fleet} server:
+
[role="screenshot"]
image::images/add-fleet-server.png[In-product instructions for adding a {fleet-server}]

*Notes:*

* Make sure you download an x64 architecture installation package.
* After generating the service token, save it to a secure location. You might
need to use this token later to scale your deployment by adding {fleet-server}s.
* The `install` command installs the {agent} as a managed service and enrolls it
in a {fleet-server} policy:
+
[source,yaml]
----
sudo ./elastic-agent install -f --fleet-server-es=http://localhost:9200 \
--fleet-server-service-token=AAEAAWVsYXN0aWMvZmxlZXQtc2VydmVyL3Rva2VuLTE2MTkxMzg3MzIzMTg6dzEta0JDTmZUZGlDTjlwRmNVTjNVQQ
----
+
If installation is successful, you'll see the {fleet-server} agent on the
*Agents* tab in *{fleet}*. Notice that the Default Fleet Server Policy is
assigned to the agent. This policy is created when you run {fleet} for the first
time.
+
[role="screenshot"]
image::images/agents-tab-fleet-server.png[Agent tab showing a healthy agent enrolled in the Default Fleet Server policy]

// end::self-managed[]
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
++++
<div class="tabs" data-tab-group="spin-up-stack">
<div role="tablist" aria-label="Spin up">
<button role="tab"
aria-selected="true"
aria-controls="cloud-tab-spinup"
id="cloud-spinup">
Elasticsearch Service
</button>
<button role="tab"
aria-selected="false"
aria-controls="self-managed-tab-spinup"
id="self-managed-spinup"
tabindex="-1">
Self-managed
</button>
</div>
<div tabindex="0"
role="tabpanel"
id="cloud-tab-spinup"
aria-labelledby="cloud-spinup">
++++

include::content.asciidoc[tag=ess]

++++
</div>
<div tabindex="0"
role="tabpanel"
id="self-managed-tab-spinup"
aria-labelledby="self-managed-spinup"
hidden="">
++++

include::content.asciidoc[tag=self-managed]

++++
</div>
</div>
++++