Jigsaw-Code / outline-apps

Outline Client and Manager, developed by Jigsaw. Outline Manager makes it easy to create your own VPN server. Outline Client lets you share access to your VPN with anyone in your network, giving them access to the free and open internet.
https://getoutline.org/
Apache License 2.0
8.39k stars 1.36k forks source link

Save the server list in Manager as fallback in case cloud provider is inaccessible #1898

Open dandaka opened 1 year ago

dandaka commented 1 year ago

How to reproduce

  1. Add DO server
  2. Open Outline Manager from time to time in a month time
  3. DO server disappears from list of servers
  4. Error message "Failed to get DigitalOcean account information"
  5. Add server again
  6. It appears for some time (month or so), then again disappears

image

fortuna commented 1 year ago

I believe the access token we get from OAuth is expiring. It used to be the case that the token would last several months. But since then DigitalOcean changed their system to make the tokens expire sooner.

We probably need to use the Refresh Token Flow as explained here: https://docs.digitalocean.com/reference/api/oauth-api/

fortuna commented 1 year ago

I guess it would also be helpful to save the server list so we can manage them even if DO is inaccessible. You wouldn't be able to delete the server, but at least you can do the rest.