Files
Windmill/f/Reporting/rdp_logins__flow/flow.yaml
T
Sebastian Serfling 2b5d29ef67 Initial commit: Windmill workspace sync
Scripts, flows, apps, resources and resource types from the Windmill workspace.
API token excluded via .gitignore (config/).
2026-04-24 09:06:07 +02:00

98 lines
3.5 KiB
YAML

summary: RDP Logins Collector
description: >
Lädt alle aktiven RDS-Server aus bronze.server, gleicht sie mit den
verbundenen rport.io Clients ab (per Hostname oder IP), führt auf jedem den
PS-Login-Collector aus und schreibt die Ergebnisse in
bronze.services.reporting.
value:
modules:
- id: find_rds_clients
summary: RDS-Server mit rport.io Clients abgleichen
value:
type: rawscript
content: '!inline rds-server_mit_rport.io_clients_abgleichen.ts'
input_transforms:
database:
type: static
value: $res:u/sebastianserfling/fascinating_mysql
rportio_api_token:
type: static
value: $var:f/Reporting/rportio_api_token
rportio_base_url:
type: static
value: $var:f/Reporting/rportio_base_url
rportio_username:
type: static
value: $var:f/Reporting/rportio_username
lock: '!inline rds-server_mit_rport.io_clients_abgleichen.lock'
language: bun
- id: process_servers
summary: Pro Server Logins sammeln und speichern
value:
type: forloopflow
modules:
- id: execute_ps
summary: PowerShell via rport.io ausführen
value:
type: rawscript
content: '!inline powershell_via_rport.io_ausführen.ts'
input_transforms:
client_id:
type: javascript
expr: flow_input.iter.value.rport_client_id
hours_back:
type: javascript
expr: flow_input.hours_back ?? 1
rportio_api_token:
type: static
value: $var:f/Reporting/rportio_api_token
rportio_base_url:
type: static
value: $var:f/Reporting/rportio_base_url
rportio_username:
type: static
value: $var:f/Reporting/rportio_username
server_ip:
type: javascript
expr: flow_input.iter.value.ipaddress
lock: '!inline powershell_via_rport.io_ausführen.lock'
language: bun
- id: insert_logins
summary: Login-Einträge in MySQL speichern
value:
type: forloopflow
modules:
- id: insert_login
summary: Einzelnen Login-Eintrag einfügen
value:
type: rawscript
content: '!inline einzelnen_login-eintrag_einfügen.ts'
input_transforms:
database:
type: static
value: $res:u/sebastianserfling/fascinating_mysql
record:
type: javascript
expr: flow_input.iter.value
lock: '!inline einzelnen_login-eintrag_einfügen.lock'
language: bun
iterator:
type: javascript
expr: results.execute_ps
parallel: false
skip_failures: false
iterator:
type: javascript
expr: results.find_rds_clients
parallel: false
skip_failures: true
schema:
$schema: https://json-schema.org/draft/2019-09/schema
type: object
properties:
hours_back:
type: integer
description: 'Wie viele Stunden zurückschauen (Standard: 1)'
default: 1
required: []