Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature - Store YAML file in a remote data store #42

Open
abdulrabbani00 opened this issue Dec 29, 2022 · 9 comments
Open

Feature - Store YAML file in a remote data store #42

abdulrabbani00 opened this issue Dec 29, 2022 · 9 comments
Labels
enhancement New feature or request

Comments

@abdulrabbani00
Copy link

It would be terrific is the user credentials could be stored in a remote data store (Deta, Mongo, etc).

I would be happy to integrate this feature if you are interested in having it incorporated.

@abdulrabbani00
Copy link
Author

I see a few solutions for this. But I think the simplest solution is:

  1. Utilize the config.yaml file for all config parameters, excluding the credentials.
  2. Within the config.yaml file, users can specify how they want the credentials stored:
credential_store: "deta"
....
credential_store: "config.yaml"
....
credential_store: "credentials.yaml"
....
  1. We continue to store and access user credentials within the code as a dictionary. The only difference is, at load and at save, depending on the credential_Store option, we store or load the credentials with a specific adapter.

@mkhorasani
Copy link
Owner

Hi @abdulrabbani00, I will look into this for a future release. Many thanks.

@VovaViliLox
Copy link

VovaViliLox commented Feb 20, 2023

Hello @mkhorasani @abdulrabbani00 , do you think it would be possible to add a flag that appends a remote data store like Deta only after a click in verification e-mail? Say, if someone were to send a registration request from example@preauthorized_domain.com, I would like to first send an expiring link to example@preauthorized_domain.com, and only after they click on a link in their e-mail I append their name.

Technically it is possible to do if this app were to be integrated with Firebase.

@abdulrabbani00
Copy link
Author

Yeah that makes sense. Although tbh I have no insensitive to do it.

If you opened a pr against my branch I would be more than happy to test and merge.

@mkhorasani
Copy link
Owner

@abdulrabbani00 @VovaViliLox apologies for the delay in investigating these PR's, will try to check/accept them very soon!

@VovaViliLox
Copy link

Yeah that makes sense. Although tbh I have no insensitive to do it.

If you opened a pr against my branch I would be more than happy to test and merge.

Yes, once I'll figure it out I for sure will open a pull request.

@iuiu34
Copy link

iuiu34 commented Oct 26, 2023

any update on this?

@mkhorasani mkhorasani added the enhancement New feature or request label Jan 22, 2024
@elmighetto
Copy link

do you think it would be possible to add a flag that appends a remote data store like Deta only after a click in verification e-mail? Say, if someone were to send a registration request from example@preauthorized_domain.com, I would like to first send an expiring link to example@preauthorized_domain.com, and only after they click on a link in their e-mail I append their name.

I've implemented something similar for my app. I hold off on writing the 'create account' updated config until the user inputs a random key sent to their email using yagmail. Once they enter it, then I write their updated user config to the remote storage so the account is actually created. Using remote storage is accomplished fairly simply by just reading and writing from a remote file instead of a local file using st_files_connection.

I think adding a note to the readme that writing the local config.yaml file does not work well when hosted on the streamlit community cloud, and a remote file system will need to be used to support account creation would be a good addition.

@drankush
Copy link

@elmighetto , can you suggest what/where are you using for hosting your remote file and you are storing it as yaml or in db.
Also you mean, once the user enters that random key, it creates credentials directly into the config.yaml on the remote file?

I will appreciate some clarity as Im trying to achieve the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants