Skip to content
This repository was archived by the owner on May 17, 2024. It is now read-only.

save and get the api key from the system keyring service #492

Conversation

pik94
Copy link
Contributor

@pik94 pik94 commented Apr 11, 2023

By default an API token to interact with the Datafold cloud is set and stored in an env variable DATAFOLD_API_KEY. However, it is not convenient is the data-diff is run across multiple terminal. So, it is better to store it somewhere else.
Current solution provides an opportunity to store the API key in the system keyring service. When a user sets the api key first time, the key is also stored in the keyring service so if DATAFOLD_API_KEY is not set in another terminal or process, it is taken from the keyring service.

Also would like to emphasize that the value from DATAFOLD_API_KEY has a higher priority than a value from the key service, the latter is rewritten in that case.

@pik94 pik94 self-assigned this Apr 11, 2023
@pik94 pik94 added --dbt Issues/features related to the dbt integration cloud Issues related to data-diff <> Datafold Cloud interaction enhancement New feature or request labels Apr 11, 2023
@pik94 pik94 merged commit acd1643 into datafold:master Apr 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
--dbt Issues/features related to the dbt integration cloud Issues related to data-diff <> Datafold Cloud interaction enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants