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
Copy file name to clipboardExpand all lines: README.md
+20-12Lines changed: 20 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,8 @@ The scripts will give you a list of all organizations in the enterprise as a CSV
7
7
> [!NOTE]
8
8
> This is an _unofficial_ tool created by Field Security Specialists, and is not officially supported by GitHub.
9
9
10
-
:information_source: This uses the [security manager role](https://docs.github.com/en/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) and parts of the GraphQL API that is available in GitHub.com (free/pro/teams and enterprise), as well as GitHub Enterprise Server versions 3.5 and higher.
10
+
> [!NOTE]
11
+
> This uses the [security manager role](https://docs.github.com/en/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) and parts of the GraphQL API that is available in GitHub.com (free/pro/teams and enterprise), as well as GitHub Enterprise Server versions 3.5 and higher.
11
12
12
13
## Scripts
13
14
@@ -30,19 +31,26 @@ The scripts will give you a list of all organizations in the enterprise as a CSV
30
31
pip install -r requirements.txt
31
32
```
32
33
33
-
1. Choose inputs as arguments to the script as follows:
34
+
1. Choose inputs as arguments to the scripts as follows:
34
35
35
-
- the server URL (for GHES, EMU, or data residency) in`--github-url`
36
+
- The server URL (for GHES, EMU, or data residency) in`--github-url`.
36
37
- For GHEC this is not required.
37
-
- call the script with the correct GitHub PAT
38
-
- place it in`GITHUB_TOKEN`in your environment, or
39
-
- create a file and save your token there to read it, and call the script with the `--token-file` argument
40
-
- use the enterprise slug as the first argument in the promote/demote scripts
41
-
- this is string URL version of the enterprise identity. It's available in the enterprise admin url (for cloud and server), e.g. `https://github.com/enterprises/ENTERPRISE-SLUG-HERE`.
42
-
- for the security manager team script:
43
-
- use the list of orgs output by `org-admin-promote.py` in `--unmanaged-orgs`
44
-
- put the name of the security manager team and the team members to add in `--team-name` and `--team-members`.
45
-
- If you are using GHES 3.15 or below, please use the `--legacy` flag to use the legacy security managers API.
38
+
- Call the scripts with the correct GitHub PAT:
39
+
- Place it in`GITHUB_TOKEN`in your environment, or
40
+
- create a file and save your token there to read it, and call the script with the `--token-file` argument.
41
+
- See progress with the `--progress` flag.
42
+
- Promote/demote scripts:
43
+
- Limit the promotion to a subset of organization slugs/names using the `--orgs` or `--orgs-file` arguments.
44
+
- For `--orgs/-o`, list them space separated after the argument.
45
+
- For `--orgs-file/-f`, put a new-line separated list of organizations in a file and provide the path.
46
+
- Use the enterprise slug as the first argument:
47
+
- This is string URL version of the enterprise identity. It's available in the enterprise admin url (for cloud and server), e.g. `https://github.com/enterprises/ENTERPRISE-SLUG-HERE`.
48
+
- By default, a list of all of the organizations in scope, and the unmanaged set, will be output to `all_orgs.csv` and `unmanaged_orgs.txt` respectively.
49
+
- You can use the `--orgs-csv` and `--unmanaged-orgs` arguments to place these elsewhere.
50
+
- Security manager team script:
51
+
- Put the name of the security manager team and the team members to add in `--team-name` and `--team-members`.
52
+
- If you are using GHES 3.15 or below, use the `--legacy` flag to use the legacy security managers API.
53
+
- Use the list of orgs output by `org-admin-promote.py` in `--unmanaged-orgs`, if you changed the output path.
0 commit comments