You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The function `applyExcludedUsersFilter` excludes selected users from the session cull. To add users to this exclusion list simply add their username to the array `excluded_users`. The current user is added to the array by default in the example.
6
+
7
+
Due to the significant impact that logging out all users would have I've included a `live_run` variable. If this is not explicitly set to `true` (the boolean, not the string) then the script will log the actions it would have taken, but not actually affect any user sessions. [(Similar to the PowerShell `WhatIf` concept)][WhatIfArticle]
8
+
9
+
## Sample Outputs
10
+
### Dry Run
11
+
```
12
+
*** Script: Live run: false: would logout sessions for UserName.With.Session.1
13
+
*** Script: Live run: false: would logout sessions for UserName.With.Session.2
14
+
*** Script: Live run: false: would logout sessions for UserName.With.Session.3
15
+
*** Script: Live run: false: Logged out sessions for the following users:
16
+
[
17
+
"UserName.With.Session.1",
18
+
"UserName.With.Session.2",
19
+
"UserName.With.Session.3"
20
+
]
21
+
```
22
+
### Live Run
23
+
```
24
+
*** Script: Live run: true: Logged out sessions for the following users:
0 commit comments