Skip to content

Commit

Permalink
Merge pull request #239 from silversword411/main
Browse files Browse the repository at this point in the history
API example for software update and automation pics
  • Loading branch information
silversword411 authored Feb 16, 2024
2 parents a39e95e + 6409b56 commit 7fb2cd9
Show file tree
Hide file tree
Showing 9 changed files with 63 additions and 1 deletion.
42 changes: 42 additions & 0 deletions docs/functions/api_examples.md
Original file line number Diff line number Diff line change
Expand Up @@ -455,3 +455,45 @@ var_dump($audit);

?>
```

## Update software using API

```
#!/rmm/api/env/bin/python
import concurrent.futures
import requests
API = "https://api.CHANGEME.com"
API_KEY = "CHANGEME"
HEADERS = {
"Content-Type": "application/json",
"X-API-KEY": API_KEY,
}
MAX_WORKERS = 10
def create_list_of_urls():
ret = []
agents = requests.get(f"{API}/agents/?detail=false", headers=HEADERS)
for agent in agents.json():
ret.append(f"{API}/software/{agent['agent_id']}/") # refresh software endpoint
return ret
def do_software_refresh(url):
r = requests.put(url, headers=HEADERS)
return r.json()
with concurrent.futures.ThreadPoolExecutor(max_workers=MAX_WORKERS) as executor:
futures = []
for url in create_list_of_urls():
futures.append(executor.submit(do_software_refresh, url))
for future in concurrent.futures.as_completed(futures):
print(future.result())
```
4 changes: 3 additions & 1 deletion docs/functions/automation_policies.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ Automation policies in Tactical RMM allow for mass deployment of Checks, Automat

You can also see a list of Relations that show what policy is applied to what Clients / Sites / Agents.

![Automation Results](images/automation_results.png)

Before you ask, [multiple automation policies](https://github.com/amidaware/tacticalrmm/issues/665) per level is in the todo list.

## Creating Automation Policies
Expand All @@ -33,7 +35,7 @@ At each level you can block policy inheritance from the level above using checkb

## Adding Windows Patch Management Policy

Under the Automation Manager you can create a Patch Policy and control what patches are applied, when, and if the computer is rebooted after.
Under the Automation Manager you can create a Patch Policy and control [what patches](../howitallworks.md#windows-update-management) are applied, when, and if the computer is rebooted after.

!!!note
Most "regular" Windows patches are listed in the "Other" category.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/functions/images/automation_results.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/2024-02-15-22-17-49.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/2024-02-15-22-22-33.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/2024-02-15-22-22-56.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/2024-02-15-22-23-48.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions docs/install_agent.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,3 +223,21 @@ wget scripturl
chmod +x rmm.sh
./rmm.sh
```

## Mac Agent Permissions

Because Mac has no automated access to permissions you must grant all permissions manually after agent install (you might need to attempt a mesh connection once after install to get mesh to appear in the security settings)

![](images/2024-02-15-22-22-56.png)

Take Control needs Screen Recording (to see anything more than the menu bar)

![](images/2024-02-15-22-23-48.png)

and Accessibility for keyboard/mouse input

![](images/2024-02-15-22-22-33.png)

tacticalagent needs full disk access for script running

![](images/2024-02-15-22-17-49.png)

0 comments on commit 7fb2cd9

Please sign in to comment.