mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-09-03 22:23:16 +00:00
Fix GitHub reader headers and add docs (#11675)
* Fix header and add docs * Format
This commit is contained in:
parent
0391ce50bf
commit
b60f198674
@ -53,7 +53,9 @@ class GitHubReader(Reader):
|
|||||||
to the API
|
to the API
|
||||||
"""
|
"""
|
||||||
if self._auth_headers is None:
|
if self._auth_headers is None:
|
||||||
self._auth_headers = {"Authentication": f"token {self.credentials.token}"}
|
self._auth_headers = {
|
||||||
|
"Authorization": f"Bearer {self.credentials.token.get_secret_value()}"
|
||||||
|
}
|
||||||
|
|
||||||
return self._auth_headers
|
return self._auth_headers
|
||||||
|
|
||||||
|
@ -103,6 +103,11 @@ properties we need to add in this case:
|
|||||||
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /codeInfo %}
|
{% /codeInfo %}
|
||||||
|
|
||||||
#### Source Configuration - Source Config
|
#### Source Configuration - Source Config
|
||||||
|
@ -103,6 +103,11 @@ properties we need to add in this case:
|
|||||||
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /codeInfo %}
|
{% /codeInfo %}
|
||||||
|
|
||||||
#### Source Configuration - Source Config
|
#### Source Configuration - Source Config
|
||||||
|
@ -194,6 +194,11 @@ Then, if we choose to inform the GitHub credentials to ingest LookML Views:
|
|||||||
- **Repository Name**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **Repository Name**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **API Token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **API Token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /extraContent %}
|
{% /extraContent %}
|
||||||
|
|
||||||
{% step srNumber=6 %}
|
{% step srNumber=6 %}
|
||||||
|
@ -103,6 +103,11 @@ properties we need to add in this case:
|
|||||||
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /codeInfo %}
|
{% /codeInfo %}
|
||||||
|
|
||||||
#### Source Configuration - Source Config
|
#### Source Configuration - Source Config
|
||||||
|
@ -103,6 +103,11 @@ properties we need to add in this case:
|
|||||||
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **repositoryName**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /codeInfo %}
|
{% /codeInfo %}
|
||||||
|
|
||||||
#### Source Configuration - Source Config
|
#### Source Configuration - Source Config
|
||||||
|
@ -194,6 +194,11 @@ Then, if we choose to inform the GitHub credentials to ingest LookML Views:
|
|||||||
- **Repository Name**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
- **Repository Name**: The name of a GitHub repository. For example, in https://github.com/open-metadata/OpenMetadata, the name is `OpenMetadata`.
|
||||||
- **API Token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
- **API Token**: Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
|
||||||
|
|
||||||
{% /extraContent %}
|
{% /extraContent %}
|
||||||
|
|
||||||
{% step srNumber=6 %}
|
{% step srNumber=6 %}
|
||||||
|
@ -58,3 +58,7 @@ The name of a GitHub repository. For example, in https://github.com/open-metadat
|
|||||||
#### API Token $(id="token")
|
#### API Token $(id="token")
|
||||||
|
|
||||||
Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
Token to use the API. This is required for private repositories and to ensure we don't hit API limits.
|
||||||
|
|
||||||
|
Follow these [steps](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-fine-grained-personal-access-token) in order to create a fine-grained personal access token.
|
||||||
|
|
||||||
|
When configuring, give repository access to `Only select repositories` and choose the one containing your LookML files. Then, we only need `Repository Permissions` as `Read-only` for `Contents`.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user