Native (email) Auth doesn't seem to work out-of-box
-
Ah I got now what you meant with the STMP settings. I didn't realize you can use that as the SSO provider in typebot. Well so it appears the optionalSso flag in Cloudron is not correct then, if typebot always requires an auth provider. Looking into this soon.
To get going you could install the app with Cloudron SSO so it has at least one setup.
-
So it seems that either we do not allow using external authentication in the app, or we have to rely on the users to setup some external auth provider which is not email. @shrey have you tried any of the others mentioned at https://docs.typebot.io/self-hosting/configuration ?
-
@nebulon said in Native (email) Auth doesn't seem to work out-of-box:
have you tried any of the others mentioned at https://docs.typebot.io/self-hosting/configuration ?
@nebulon Nope, as my current use-case requires the use of email based auth only.
-
So if your auth provider is required to some SMTP server, then I guess this can't work if our packaging code also sets up SMTP for transactional emails and that always goes to your Cloudron's email server.
However given that we
source /app/data/env.sh
in thestart.sh
AFTER we setup the SMTP variables, you should be able to overwrite those.I guess then it is a matter of figuring out what the correct env vars for SMTP auth are for typebot, however that is a bit out of scope for Cloudron itself.
Edit: while trying your custom settings, I guess also keep an eye on the SMTP server logs itself to get an idea why things may fail
-
I don't think this is a strictly "SMTP" related issue. Even for auth, the Cloudron configured email should work just fine.
Update:
Yes, confirmed that the issue is that the Typebot instance is not aware of the available SMTP settings at all.
Example, the following defaults in the "env.sh" have been able to get my Typebot instance going properly now:
export SMTP_USERNAME="$CLOUDRON_MAIL_SMTP_USERNAME" export SMTP_PASSWORD="$CLOUDRON_MAIL_SMTP_PASSWORD" export SMTP_HOST="$CLOUDRON_MAIL_SMTP_SERVER" export SMTP_PORT="$CLOUDRON_MAIL_SMTP_PORT" export NEXT_PUBLIC_SMTP_FROM="$CLOUDRON_MAIL_FROM_DISPLAY_NAME <$CLOUDRON_MAIL_FROM>" export SMTP_SECURE="false" export SMTP_AUTH_DISABLED="false"
Recommendation: have the above config set by default, particularly in the cases where the admin selects "User Management by app", when installing the app.
-
@shrey said in Native (email) Auth doesn't seem to work out-of-box:
Recommendation: have the above config set by default, particularly in the cases where the admin selects "User Management by app", when installing the app.
Those variables are always set already. See https://git.cloudron.io/cloudron/typebot-app/-/blob/main/start.sh?ref_type=heads#L31 . Or maybe you are suggesting that we should put this in
/app/data/env.sh
so that the user can see them?