fleet/docs
Lucas Manuel Rodriguez e7f61305a9
New APIs to add/remove manual labels to/from a host (#18283)
#16767

To create a manual label:
```sh
cat labels.yml
---
apiVersion: v1
kind: label
spec:
  name: Manually Managed Example
  label_membership_type: manual
  hosts:
    - lucass-macbook-pro.local
```

To add/delete a manual label to/from a host:
```
curl -k -v -X POST -H "Authorization: Bearer $TEST_TOKEN" https://localhost:8080/api/latest/fleet/hosts/1/labels -d '{"labels": ["Manually Managed Example"]}'

curl -k -v -X DELETE -H "Authorization: Bearer $TEST_TOKEN" https://localhost:8080/api/latest/fleet/hosts/1/labels -d '{"labels": ["Manually Managed Example"]}'
```

API draft changes: https://github.com/fleetdm/fleet/pull/16979/files
Figma with error strings:
https://www.figma.com/file/JiWoAiuHlkt76s3o3Uyz6h/%2316767-API-endpoint-for-updating-a-host's-manual-labels?type=design&node-id=2-130&mode=design&t=pxRPhrn6E1bOCrEd-0

- [X] Changes file added for user-visible changes in `changes/`,
`orbit/changes/` or `ee/fleetd-chrome/changes`.
See [Changes
files](https://fleetdm.com/docs/contributing/committing-changes#changes-files)
for more information.
- [X] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)
~- [ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- ~[ ] If database migrations are included, checked table schema to
confirm autoupdate~
- ~For database migrations:~
- ~[ ] Checked schema for all modified table for columns that will
auto-update timestamps during migration.~
- ~[ ] Confirmed that updating the timestamps is acceptable, and will
not cause unwanted side effects.~
- ~[ ] Ensured the correct collation is explicitly set for character
columns (`COLLATE utf8mb4_unicode_ci`).~
- [x] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2024-04-16 06:37:58 -03:00
..
01-Using-Fleet/standard-query-library Updated 1Password policy to only search 1 level deep for performance reasons. (#18003) 2024-04-04 09:33:17 -05:00
Configuration Removed current_instance_checks from docs. (#18186) 2024-04-15 10:25:04 -05:00
Contributing Add missing searchable fields to docs (#17825) 2024-04-12 17:34:38 -04:00
Deploy Update end user auth and SSO docs (#18127) 2024-04-12 16:39:56 -05:00
files Create 2022-04-29-fleet-penetration-test.pdf (#5658) 2022-05-10 10:26:10 -04:00
Get started Update FAQ.md (#17707) 2024-03-30 02:33:41 -05:00
images Migrate Deploy Fleet on Hetzner Cloud (#13021) 2023-08-30 19:17:22 -05:00
REST API Removed current_instance_checks from docs. (#18186) 2024-04-15 10:25:04 -05:00
Using Fleet New APIs to add/remove manual labels to/from a host (#18283) 2024-04-16 06:37:58 -03:00
README.md Update positioning in documentation readme and CTA example (#12464) 2023-07-17 12:38:07 -07:00

Fleet documentation

Welcome to the documentation for Fleet, the lightweight management platform for laptops and servers.

You can also read the Fleet docs over at https://fleetdm.com/docs.

Using Fleet

Resources for using the Fleet UI, fleetctl CLI, and Fleet REST API.

Deploying

Resources for installing Fleet's infrastructure dependencies, configuring Fleet, deploying osquery to hosts, and viewing example deployment scenarios.

Contributing

If you're interested in interacting with the Fleet source code, you'll find information on modifying and building the code here.


If you have any questions, please don't hesitate to File a GitHub issue or join us on Slack. You can find us in the #fleet channel.