zorn-v / nextcloud-social-login

GNU Affero General Public License v3.0
199 stars 138 forks source link

[feature request] Display auth options based on Nextcloud URL #266

Closed kunago closed 3 years ago

kunago commented 3 years ago

I would like to ask whether anyone has had the need to display different auth methods based on the Nextcloud URL. As it stands, Nextcloud can be run on multiple domains. In my case though I would like to limit the display of certain auth methods to certain URLs only.

This is the reason:

Having displayed both of those auth button on both URLs is not really useful as the clicking on auth service of domain1.com from the cloud.domain2.com results in an error anyways.

I found the corresponding lines in the "Application.php" file that could possibly filter the method to be displayed but I would prefer not to hack the module to achieve this behavior. A simple regex, or even "strpos" check would do perfectly fine.

zorn-v commented 3 years ago

There is some problems

  1. Need new element in settings page.
  2. Only you (by this moment) need this feature.
  3. Need to bloat already bloated settings page only for you.

Really, who need different behavior on different domains ? Why to not configure redirects in webserver ?

kunago commented 3 years ago

Hello, thank you for the feedback. So as for the points:

  1. I am aware of that
  2. I was not aware of that, hence the suggestion
  3. It does not need to be done for me in the first place, it was a suggestion only

Maybe I expressed myself in a bad way but given the answer, i think I will handle it.