synchrone / sandstorm-radicale

A calendars and contacts app for Sandstorm.io
https://apps.sandstorm.io/app/8kr4rvyrggvzfvc160htzdt4u5rfvjc2dgdn27n5pt66mxa40m1h
13 stars 3 forks source link

CalDAV link changes after grain restart #19

Closed iartarisi closed 8 years ago

iartarisi commented 8 years ago

The CalDAV sync API URI seems to change every time there is a grain restart on sandstorm. This makes syncing/using the caldav server from another interface impossible AFAIU. It seems that I would need to keep the sandstorm webapp open all the time so the radicale grain doesn't get restarted.

synchrone commented 8 years ago

Sync API URI contains HTTP Basic username-dependant dynamic subdomain in it. It is expected that it would be changing not only with grain restart, but with Sync dialog re-open, since a new pair of credentials is requested from Sandstorm every time. If those credentials are not used in 5 minutes after generation - they are invalidated.

However, credentials that were generated and used (!) within 5 minutes of opening that dialog remain valid and are visible in the web-keys dropdown. They also remain valid if the grain was put to sleep, and access to such API endpoint actually wakes up the grain.

iartarisi commented 8 years ago

Awesome. Thank you for the clarification. I did have an active web-key in the dropdown, but there seems to be no way to see the password for that after it's been created. So I had to setup the CalDAV integration again in my client using a new URI and username/password.