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

add disable-auth for serve command to avoid login, useful when serve shiori behind SSO (like authelia) #436

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

chain710
Copy link
Contributor

  • use disable-auth to avoid login, useful when serve shiori behind SSO (like authelia)

- use disable-auth to avoid login, useful when serve shiori behind SSO (like authelia)
@fmartingr
Copy link
Member

Hey @chain710, thanks for the PR!

I believe a better implementation for this would be leaving the login endpoint as it is, but if the flag is provided (which I would rename to single-user to follow #352) it would:

  • Check if the database has at least one admin user:
    • If not, create the gopher/shiori user in the database
    • If it only has one, login that user directly (to allow for people that already has their user set up)
    • If it has more than one, return an error and prevent usage

What do you think?

@chain710
Copy link
Contributor Author

Thank you for the advice. This takes more work, I'll look to it later

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

Successfully merging this pull request may close these issues.

None yet

2 participants