|
1 |
| -# KW GitHub Provider |
| 1 | +--- |
| 2 | +# generated by https://github.com/hashicorp/terraform-plugin-docs |
| 3 | +page_title: "kwgithub Provider" |
| 4 | +description: |- |
| 5 | + The KW GitHub provider is used to interact with GitHub resources specific to Knowledge Work organization. |
| 6 | +--- |
2 | 7 |
|
3 |
| -The KW GitHub provider is used to interact with GitHub resources specific to Knowledge Work organization. |
4 |
| - |
5 |
| -## Authentication |
| 8 | +# kwgithub Provider |
6 | 9 |
|
7 |
| -The provider supports two authentication methods: |
| 10 | +The KW GitHub provider is used to interact with GitHub resources specific to Knowledge Work organization. |
8 | 11 |
|
9 |
| -### Personal Access Token |
| 12 | +## Example Usage |
10 | 13 |
|
11 | 14 | ```terraform
|
12 | 15 | provider "kwgithub" {
|
13 | 16 | token = var.github_token
|
14 | 17 | owner = "knowledge-work"
|
15 | 18 | }
|
16 |
| -``` |
17 | 19 |
|
18 |
| -### GitHub App Installation |
19 |
| - |
20 |
| -```terraform |
| 20 | +# GitHub App authentication example |
21 | 21 | provider "kwgithub" {
|
22 | 22 | owner = "knowledge-work"
|
23 | 23 | app_auth {}
|
24 | 24 | }
|
25 | 25 | ```
|
26 | 26 |
|
27 |
| -## Configuration |
28 |
| - |
29 |
| -### Arguments |
| 27 | +<!-- schema generated by tfplugindocs --> |
| 28 | +## Schema |
30 | 29 |
|
31 |
| -* `token` - (Optional) GitHub personal access token. Can also be set via `GITHUB_TOKEN` environment variable. |
32 |
| -* `owner` - (Optional) GitHub owner name to manage. Can also be set via `GITHUB_OWNER` environment variable. |
33 |
| -* `github_base_url` - (Optional) GitHub base URL. Defaults to https://api.github.com. Can also be set via `GITHUB_BASE_URL` environment variable. |
34 |
| -* `app_auth` - (Optional) Configuration block to use GitHub App installation token. Conflicts with `token`. |
35 |
| - * `id` - (Optional) GitHub App ID. Can also be set via `GITHUB_APP_ID` environment variable. |
36 |
| - * `installation_id` - (Optional) GitHub App installation ID. Can also be set via `GITHUB_APP_INSTALLATION_ID` environment variable. |
37 |
| - * `pem_file` - (Optional) GitHub App private key PEM file contents. Can also be set via `GITHUB_APP_PEM_FILE` environment variable. |
| 30 | +### Optional |
38 | 31 |
|
39 |
| -### Environment Variables |
| 32 | +- `app_auth` (Block List) GitHub App authentication configuration. Conflicts with token. (see [below for nested schema](#nestedblock--app_auth)) |
| 33 | +- `github_base_url` (String) GitHub base URL. Defaults to https://api.github.com. Can also be set via GITHUB_BASE_URL environment variable. |
| 34 | +- `owner` (String) GitHub owner name to manage. Can also be set via GITHUB_OWNER environment variable. |
| 35 | +- `token` (String, Sensitive) GitHub personal access token. Can also be set via GITHUB_TOKEN environment variable. |
40 | 36 |
|
41 |
| -When using environment variables, an empty `app_auth` block is required to allow provider configurations from environment variables to be specified: |
42 |
| - |
43 |
| -```terraform |
44 |
| -provider "kwgithub" { |
45 |
| - owner = "knowledge-work" |
46 |
| - app_auth {} |
47 |
| -} |
48 |
| -``` |
| 37 | +<a id="nestedblock--app_auth"></a> |
| 38 | +### Nested Schema for `app_auth` |
49 | 39 |
|
50 |
| -Set the following environment variables: |
51 |
| -- `GITHUB_APP_ID` |
52 |
| -- `GITHUB_APP_INSTALLATION_ID` |
53 |
| -- `GITHUB_APP_PEM_FILE` |
| 40 | +Optional: |
54 | 41 |
|
55 |
| -Note: If you have a PEM file on disk, you can pass it in via `pem_file = file("path/to/file.pem")`. |
| 42 | +- `id` (String) GitHub App ID. Can also be set via GITHUB_APP_ID environment variable. |
| 43 | +- `installation_id` (String) GitHub App installation ID. Can also be set via GITHUB_APP_INSTALLATION_ID environment variable. |
| 44 | +- `pem_file` (String, Sensitive) GitHub App private key PEM file contents. Can also be set via GITHUB_APP_PEM_FILE environment variable. |
0 commit comments