Skip to content

Staying logged into Cloudant #54

New issue

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

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

Already on GitHub? # to your account

Open
FarSideHub opened this issue Mar 14, 2018 · 6 comments
Open

Staying logged into Cloudant #54

FarSideHub opened this issue Mar 14, 2018 · 6 comments

Comments

@FarSideHub
Copy link

FarSideHub commented Mar 14, 2018

I'm not sure whether this is an appropriate place to ask, so I'm sorry if the general google group would've been better.

I'd like to be able to stay logged in to Cloudant. One or another of my devices will log out every now and then, which is really frustrating.

I could only get NoteSelf set up because of Carl Kibler's comment on the 'Configure NoteSelf Sync' video (Thanks Carl! I think I'll quote it at the bottom of this post in case it'll help anyone reading.)

Is there a way to stay logged in or use the Cloudant API? I had a quick try, but I don't really understand how it works, tbh.

Sorry I couldn't work out how to label this post 'Help Wanted' either.


Carl Kibler
1 month ago
(not the original video poster)
I will try a screencast showing how to do this with the updated UI at BlueMix/Cloudant. 

In short:
There are 2 separate admin UIs. One is for your Cloudant instances as a BlueMix resource, then one for the Cloudant DB itself.

In the first, you should see Manage, Service Credentials, Plan, and Connections. Under Service Credentials, generate one. The very long URL created is the one you need for NoteSelf - it contains username and password embedded in the URL.

Then do "Launch" button from the Manage page. Create a Database. The name you give it, like 'tiddlywiki' is what goes into NoteSelf for Database Name field. 

Then also do the CORS change shown in the video.`
@danielo515
Copy link
Contributor

danielo515 commented Mar 21, 2018

Hello @FarSideHub , welcome to the community.
Thanks for your report and for using NoteSelf.

I'm not sure whether this is an appropriate place to ask, so I'm sorry if the general google group would've been better.

This is a perfect place for this kind of questions. The google groups is too noisy to catch my attention about an specific topic, so feel free to post whatever you need here until we create a forum for NS.

I'd like to be able to stay logged in to Cloudant. One or another of my devices will log out every now and then, which is really frustrating.

This is on my todo-list: danielo515/tiddlypouch#69 . I admit that it is very frustrating.
The best solution involves creating an api token when you login and then store that token. This way you will be able to delete the token if it is required at any moment.
Sadly this requires some programming on the server side, and my plan is to create a NoteSelf service with this functionality. This will be my priority over anything else.
Another solution would involve saving the credentials inside the browser storage in a more or less secure way. At the end, browser storage it's suppossed to be only accesible from apps on the same domain.
What we do know is trying to keep the cookie alive as soon as NoteSelf is open, so this is an improvement from the previous implementation.

Anyway, I understand your frustration because it happens to me too. This is specially problematic now that the cloudant interface has changed and the way it is used and credentials are very long and cumbersome.

I could only get NoteSelf set up because of Carl Kibler's comment on the 'Configure NoteSelf Sync' video

Could you share that video ? It will be awesome to include it on the FAQ.

Sorry I couldn't work out how to label this post 'Help Wanted' either.

Only the repository owner can add tags, don't worry about it. In this repository Help Wanted means that we as NoteSelf owners want help trying to implement or document something. User questions are labeled as question.

Regards

@FarSideHub
Copy link
Author

FarSideHub commented Mar 21, 2018 via email

@johnd0e
Copy link

johnd0e commented Oct 2, 2018

This is specially problematic now that the cloudant interface has changed and the way it is used and credentials are very long and cumbersome.

I see there are some node.js libraries that should make hardest part: transform api key into bearer token.
Is it possible to use them in NS?

@schnittchen
Copy link

I have my own setup with a self-hosted couchdb and also suffer from this problem. It seems a login does not survive a single day, which is a major annoyance.

I'll check if adding user@password style credentials to the couchdb url fixes this. I doubt it does because the login workflow is unaware of this. Naturally, it takes a while to know if it works.

@FarSideHub
Copy link
Author

FarSideHub commented May 23, 2021 via email

@danielo515
Copy link
Contributor

danielo515 commented Jun 21, 2021

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

4 participants