Notes
- Console 4.4.0 introduces minimum capabilities for working with Amazon EC2 and VMware Sphere cloud resources.
- This configuration is only required if you intend to use the Resource Management features.
- As of Console 4.6.0, discovered resources appear in the Resources page.
- There is an API endpoint available to perform discovery and retrieve the resource list.
- There is an API endpoint available to submit a list of vSphere resources.
Requirements
- Console 4.4.0 or later
- For Fetching VMware vSphere Resources, Console 4.4.1 or later required
- For viewing resources in the UI, Console 4.6.0 or later required
- Complete console API configuration below
Console API Configuration
- Generate a Console server API token on the command line:
capsule8-console generate-token
- When sending an API requests that to the Console server, include the HTTP header
Authorization: Bearer <token>
where <token> is the one you just generated.
AWS EC2 Configuration
- The Console server needs two new IAM permissions in order to identify EC2 instances. The required permissions are ec2:DescribeRegions and ec2:DescribeInstances.
- Create or update an IAM entity with those permissions.
- We recommend using the minimum set of required permissions, following the security principle of least privilege.
- Generate AWS API credentials for that entity.
- Set environment variables for the Console server:
- AWS_ACCESS_KEY_ID=<newly generated key ID>
- AWS_SECRET_ACCESS_KEY=<newly generated secret>
- CAPSULE8_CONSOLE_EC2_RESOURCE_DISCOVERY_ENABLED="true"
- Restart the Console server.
VMware vSphere Configuration
Fetching VMware vSphere Resources
- The console will need the server ip, username, and password in order fetch vsphere resources.
- Set environment variables for the Console server:
- CAPSULE8_CONSOLE_VMWARE_RESOURCE_DISCOVERY_ENABLED="true"
- CAPSULE8_CONSOLE_VMWARE_RESOURCE_DISCOVERY_URL="https:/[vsphere host]
- CAPSULE8_CONSOLE_VMWARE_RESOURCE_DISCOVERY_USERNAME="[vsphere user]"
- CAPSULE8_CONSOLE_VMWARE_RESOURCE_DISCOVERY_PASSWORD="[vsphere pass]"
- # Only use insecure if you cannot install the vsphere server's ssl certificate on the console host:
- CAPSULE8_CONSOLE_VMWARE_RESOURCE_DISCOVERY_INSECURE=[true | false]
- Restart the Console server.
Uploading vSphere Resources
- Create a CSV file for the inventory. The required headers are UUID, Name, and Tags.
- Upload the file by making a POST request to
https://<console-url>/assets/upload
with file contents in the body. If using curl you will need the data-binary option so that new lines are preserved.
Retrieving the Resource List from the API
The retrieved resource list here could include: sensor heartbeat metadata, resources uploaded by CSV for vSphere, and resources found by AWS discovery and vSphere discovery.
- Make sure to perform the "Console API Configuration" steps above.
- Make an HTTP request to
https://<console-url>/resources/discover
Comments
0 comments
Please sign in to leave a comment.