|
1 | 1 | [#ecctl_deployment_apm_create]
|
2 | 2 | == ecctl deployment apm create
|
3 | 3 |
|
4 |
| -Creates an APM instance in the selected deployment |
| 4 | +Creates an Apm instance |
5 | 5 |
|
6 | 6 | [float]
|
7 | 7 | === Synopsis
|
8 | 8 |
|
9 |
| -Creates an APM instance in the selected deployment |
| 9 | +Creates an APM deployment, limitting the creation scope to APM resources. |
| 10 | +There are a few ways to create an APM deployment, sane default values are provided, making |
| 11 | +the command work out of the box even when no parameters are set. When version is not specified, |
| 12 | +the matching elasticsearch deployment version will be used. These are the available options: |
10 | 13 |
|
| 14 | +* Simplified flags: --zones +++<zone count="">+++--size +++<node memory="" in="" MB="">++++++</node>++++++</zone>+++ |
| 15 | +* File definition: --file=+++<file path="">+++(shorthand: -f). The definition can be found in: https://www.elastic.co/guide/en/cloud-enterprise/current/definitions.html#ApmPayload+++</file>+++ |
| 16 | + |
| 17 | +As an option, "--generate-payload" can be used in order to obtain the generated ApmPayload |
| 18 | +that would be sent as a request, save it, update or extend the topology and create an Apm |
| 19 | +deployment using the saved payload with the "--file" flag. |
| 20 | + |
| 21 | +---- |
| 22 | +ecctl deployment apm create --id <deployment-id> [flags] |
11 | 23 | ----
|
12 |
| -ecctl deployment apm create -f <file definition> --id <deployment id> [flags] |
| 24 | + |
| 25 | +[float] |
| 26 | +=== Examples |
| 27 | + |
| 28 | +---- |
| 29 | +## Create a single APM server. The command will exit after the API response has been returned, |
| 30 | +## without waiting until the deployment resources have been created. To make the command wait until |
| 31 | +the resources have been created use the "--track" flag. |
| 32 | +$ ecctl deployment apm create --id=a57f8b7ce54c4afb90ce3755d1e94000 --track |
| 33 | +{ |
| 34 | + "id": "a57f8b7ce54c4afb90ce3755d1e94000", |
| 35 | + "name": "a57f8b7ce54c4afb90ce3755d1e94000", |
| 36 | + "resources": [ |
| 37 | + { |
| 38 | + "elasticsearch_cluster_ref_id": "elasticsearch", |
| 39 | + "id": "53d104a432a648f68ec76d52ecb521d5", |
| 40 | + "kind": "apm", |
| 41 | + "ref_id": "apm", |
| 42 | + "region": "ece-region" |
| 43 | + }, |
| 44 | + { |
| 45 | + "elasticsearch_cluster_ref_id": "elasticsearch", |
| 46 | + "id": "39e4a65fc2b14651b666aaff18a13b8f", |
| 47 | + "kind": "kibana", |
| 48 | + "ref_id": "kibana", |
| 49 | + "region": "ece-region" |
| 50 | + }, |
| 51 | + { |
| 52 | + "cloud_id": "a57f8b7ce54c4afb90ce3755d1e94000:MTkyLjE2OC40NC4xMC5pcC5lcy5pbzo5MjQzJGQzODIwOWU4ZTYwYzRlYTliY2UzMDc1OThhMTljNGI3JDM5ZTRhNjVmYzJiMTQ2NTFiNjY2YWFmZjE4YTEzYjhm", |
| 53 | + "id": "d38209e8e60c4ea9bce307598a19c4b7", |
| 54 | + "kind": "elasticsearch", |
| 55 | + "ref_id": "elasticsearch", |
| 56 | + "region": "ece-region" |
| 57 | + } |
| 58 | + ] |
| 59 | +} |
| 60 | +Cluster [53d104a432a648f68ec76d52ecb521d5][Apm]: running step "wait-until-running" (Plan duration 1.38505959s)... |
| 61 | +Cluster [39e4a65fc2b14651b666aaff18a13b8f][Kibana]: finished running all the plan steps (Total plan duration: 1.73493053s) |
| 62 | +Cluster [d38209e8e60c4ea9bce307598a19c4b7][Elasticsearch]: finished running all the plan steps (Total plan duration: 1.849794895s) |
| 63 | +Cluster [53d104a432a648f68ec76d52ecb521d5][Apm]: running step "set-maintenance" (Plan duration 11.162178491s)... |
| 64 | +Cluster [53d104a432a648f68ec76d52ecb521d5][Apm]: finished running all the plan steps (Total plan duration: 16.677195277s) |
| 65 | +
|
| 66 | +## Save the definition to a file for later use. |
| 67 | +$ ecctl deployment apm create --generate-payload --id a57f8b7ce54c4afb90ce3755d1e94000 --zones 2 --size 2048 > apm_create_example.json |
| 68 | +
|
| 69 | +## Create the deployment piping through the file contents tracking the creation progress |
| 70 | +$ cat apm_create_example.json | dev-cli deployment apm create --track --id a57f8b7ce54c4afb90ce3755d1e94000 |
| 71 | +[...] |
13 | 72 | ----
|
14 | 73 |
|
15 | 74 | [float]
|
16 | 75 | === Options
|
17 | 76 |
|
18 | 77 | ----
|
19 |
| - -f, --file string Deployment definition |
20 |
| - -h, --help help for create |
21 |
| - --id string Overrides the deployment ID on which it's tied |
22 |
| - --track Tracks the progress of the performed task |
| 78 | + --deployment-template string Optional deployment template ID, automatically obtained from the current deployment |
| 79 | + --elasticsearch-ref-id string Optional Elasticsearch ref ID where the Apm deployment will connect to |
| 80 | + -f, --file string ApmPayload file definition. See help for more information |
| 81 | + --generate-payload Returns the ApmPayload without actually creating the deployment resources |
| 82 | + -h, --help help for create |
| 83 | + --id string Deployment ID where to create the Apm deployment |
| 84 | + --name string Optional name to set for the Apm deployment (Overrides name if present) |
| 85 | + --ref-id string RefId for the Apm deployment (default "main-apm") |
| 86 | + --size int32 Memory (RAM) in MB that each of the deployment nodes will have (default 512) |
| 87 | + -t, --track Tracks the progress of the performed task |
| 88 | + --version string Optional version to use. If not specified, it will default to the deployment's stack version |
| 89 | + --zones int32 Number of zones the deployment will span (default 1) |
23 | 90 | ----
|
24 | 91 |
|
25 | 92 | [float]
|
|
0 commit comments