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

Missing setting to send welcome mail when creating a user #11172

Closed
JB1985 opened this issue Sep 11, 2018 · 35 comments · Fixed by #19664
Closed

Missing setting to send welcome mail when creating a user #11172

JB1985 opened this issue Sep 11, 2018 · 35 comments · Fixed by #19664

Comments

@JB1985
Copy link

JB1985 commented Sep 11, 2018

I am missing the setting to disable/enable to send a welcome mail when creating a user.

Currently, an email is always sent, whether you want it or not.

In Nextcloud 13:

unbenannt

In Nextcloud 14:

unbenannt1

Please bring back the setting that the admin can disable/enable the welcome mail.

Server configuration

Operating system: Debian 9

Web server: Apache2.4

Database: MariaDB

PHP version: PHP7.0

Nextcloud version: 14.0.0

Updated from an older Nextcloud/ownCloud or fresh install: Updated from 13.0.6 and fresh install.

Where did you install Nextcloud from:

@nextcloud-bot
Copy link
Member

GitMate.io thinks possibly related issues are #8377 (Missing email field when admin create/add new user), #1011 (Error while re-creating a user), #3346 (Left shadow in app-navigation missing from user settings), #10916 (Unable to set quota when adding a new user), and #4654 (Missing expected parameters in change user hook when setting avatar).

@JB1985
Copy link
Author

JB1985 commented Sep 13, 2018

@nickvergessen can you please add this setting again?

@nickvergessen
Copy link
Member

@skjnldsv was there a discussion about this, or just an accident like the "Add group" thingy?

@skjnldsv
Copy link
Member

@nickvergessen Nope, I remember a discussion about this.
Can't find it though!
IIrc it was that it wasn't really that much used and it's better to just send a mail for everyone anyway.

@skjnldsv
Copy link
Member

#8856
#8864
#8824

@JB1985
Copy link
Author

JB1985 commented Sep 13, 2018

IIrc it was that it wasn't really that much used and it's better to just send a mail for everyone anyway.

That is a very bad consideration! Why do not you want the users to decide whether to send an email or not?
There are enough providers who send the welcome mail via another tool.

Please add this setting again.

@JB1985
Copy link
Author

JB1985 commented Sep 20, 2018

@nickvergessen

Is it still possible that the email settings comes back in NC14? In the RC1 is not there.

@nickvergessen
Copy link
Member

nickvergessen commented Sep 20, 2018

No, it will be part of 14.0.2, if someone does it

@JB1985
Copy link
Author

JB1985 commented Oct 5, 2018

Still not fixed in 14.0.2 RC1

@skjnldsv
Copy link
Member

skjnldsv commented Oct 5, 2018

@nickvergessen no it will not as this is the default behaviour that people wanted when the discussion was on iirc.

@arnowelzel
Copy link
Contributor

arnowelzel commented Oct 12, 2018

Why removing a feature like this anyway? If one wants an email, it can be enabled in the setting - so where was the problem just leaving the feature as it was in NC13?

@JB1985
Copy link
Author

JB1985 commented Nov 1, 2018

Is there any news as to whether the problem is resolved? Or will this no more fixed in this version?

Please let us know.

@arnowelzel
Copy link
Contributor

arnowelzel commented Nov 1, 2018

Please confirm my assumption:

The e-mail will only be sent, if there is no password for the user - otherwise no e-mail will be sent, right?

In this case indeed the option makes no sense. Why should anyone create a new user without setting a password and does not want to get the user told the automatically created password via e-mail? If you want to avoid e-mails getting sent, just enter a password for new users when creating them, right?

@jonasgarstick
Copy link

Please confirm my assumption:

The e-mail will only be sent, if there is no password for the user - otherwise no e-mail will be sent, right?

In this case indeed the option makes no sense. Why should anyone create a new user without setting a password and does not want to get the user told the automatically created password via e-mail? If you want to avoid e-mails getting sent, just enter a password for new users when creating them, right?

Here is a scenario: As an administrator you would like to prepare all users in the Nextcloud administration before a specific event, launch or rollout date. It would be very elegant if you don't have to create a password for every user and you could send the welcome mail at a later date or time so all users could set their passwords independently.

@arnowelzel
Copy link
Contributor

@jonasgarstick In fact is not possible to manually create users without password when the option "send e-mail to new user" is turned off in NC 13. But in this case, you also can not add an e-mail address, only username and password:

image

In fact you have to add the e-mail address later in the user details.

@kainhofer
Copy link

I'm in the same situation as @jonasgarstick describes: I'm currently setting up a new server for a professional association and I need to prepare the users now, while the nextcloud instance is not even publically available. Still, whenever I add a user, nextcloudl will send this annoying welcome mail to (future!) users who do not even know me and who have NOT agreed to receive such mails from me.

A similar situation happened to me on my day job, where we license a set of parameters from PIA Kaiserslautern and they simply set up a Nextcloud account and shared the data. However, the welcome mail seemed VERY UNPROFESSIONAL to me.
Providing access via NextCloud is fine, but there were two main issues in a professional surrounding:

  • The language of the welcome mail does not give users who did not create the account themslf any clue what Nextcloud is and why an account was added at all. Even worse, the default is to call users with the informal "Du" in Geman, which is a big No-No in a professional setting.
  • Access to the nextcloud site was not directly possible anyway (another layer of http basic auth), so clicking on the "Go to nextcloud" link didn't even work. They had to send me another mail with the http credentials to reach the login page in the first place, where they also included the NextCloud login.

Altogether, to me this was a very unprofessional episode of a Nextcloud encounter in my office job and it is mainly due to NextCloud sending those invitations automatically. In my situation all it did was to confuse me and shed a bad light on the other company.

So, please make it possible again to suppress those welcome messages. There are several scenarios where you do not want these messages sent by NextCloud, either because you don't want to inform your users yet, or because you need to contact them via other means anyway with additional information.

@arnowelzel
Copy link
Contributor

arnowelzel commented Jan 5, 2019

@kainhofer An email is only sent, when you don't add a password - otherwise the users would not be able to login. So a workaround is to add a password as well when creating the users. You have to tell the users the password anyway.

Edit: I stand corrected. Indeed the e-mail is sent even if you set the password manually. In this case I also vote for bringing this feature back.

@JB1985
Copy link
Author

JB1985 commented Jan 6, 2019

I want it still back too.

@Tom31100
Copy link

I want it back too !
And the ability to edit the text that will be sent inside nextcloud would be very nice too !

If you don't want mails to be sent, you can enter a wrong password in the mail server parameters.
This way, you can create users and groups, then reactivate the mail server with the right password.

Not pretty, but works...

@noresistence
Copy link

In our case, it would be very important to be able to disable the welcome message, as it brings an unwanted information disclosure to the users.
We have an external user and group management and create and synchronise users with the API automatically. They can then log in with the social login app and our OAuth sever.

The Problem here:

  1. the users should not receive a welcome mail at all; we have our own means to inform them about their access to the Nextcloud
  2. The users will be created before they even know that they have been accepted. After their application for the participation in an event, they will be created in the participant's database some days before we send out the notification by postal mail to them that they have been accepted. They should not be notified before that. Due to the user synchronization among our systems, including nextcloud, it is very problematic that Nextcloud sends automatic welcome messages. It would not be a problem if we could simply disable the welcome message.

Right now, I had to enter invalid Email credentials into the nextcloud settings to prevent it from sending mails. That is unfortunate and not elegant, because it disables all mail notifications.

I do not really understand what the problem of this setting is, anyway. If a majority is not using it, or if this would be a bad default, this still does not make it a useless setting as long as a sensible default value is chosen. I would be fine, even prefer, with this setting being exposed in the config.php and not the user interface.

@DylannCordel
Copy link

we have more or less a mixed workflow explained by @Tom31100 and @noresistence to create users via API:

  1. prepare user data with :
    • a random and unsused password (users can only sign-in via Keycloak SSO)
    • remove user's email from the data
  2. create the user
  3. re-add email in user data
  4. update the user to re-add email and some other extra informations

That's not really elegant but it works...

IMHO, Nextcloud should have a global setting to create user without welcome email (and without password when SSO is used).

@nickvergessen @skjnldsv If your agree to add this setting, I can PR the feature this week by:

  • adding a setting welcome_email in config.php (default to True) and update places where "welcome email" is used (user creation, "resend welcome email" feature...)
  • adding a param "welcome_email" to apps/provisionning_api/lib/Controller/UsersController->addUser (default to True) to be able to disable the welcome email when creating a specific user via API.
  • adding an option "welcome_email" to core/Command/User/Add (default to True) to be able to disable the welcome email when creating a specific user via command.

@skjnldsv
Copy link
Member

skjnldsv commented Jun 3, 2019

@DylannCordel thanks for the help :)

  • adding a setting welcome_email in config.php (default to True) and update places where "welcome email" is used (user creation, "resend welcome email" feature...)

I can already tell you we will not go this way :/
We tend to keep our options configs set low to ease the user experience.

Regarding this old issue, we should probably take position here.
I agree that this is an issue in some ways, we should be able to disable sending welcome emails. Though not in a config.php key.
Nonetheless, it also break the flow to have this into the bottom left settings area as the new user creation form is on top.

@jancborchardt what about a config toggle on the inline form (three dot menu and checkbox) to enable/disable (and remember) the setting (which is enabled by default)
And then any further new users forms that are sent reflect the option?

This will go with :

  • adding a param "welcome_email" to apps/provisionning_api/lib/Controller/UsersController->addUser (default to True) to be able to disable the welcome email when creating a specific user via API.

@jancborchardt
Copy link
Member

what about a config toggle on the inline form (three dot menu and checkbox) to enable/disable (and remember) the setting (which is enabled by default)

@skjnldsv that sounds like a good solution. 👍

@skjnldsv skjnldsv added 1. to develop Accepted and waiting to be taken care of enhancement and removed bug labels Jun 3, 2019
@systems-levigo

This comment has been minimized.

@jancborchardt
Copy link
Member

Current status is still the last 2 comments of @skjnldsv and me. Just waiting for someone to pick it up, maybe one of the people in this thread? :)

@Beeez
Copy link

Beeez commented Feb 5, 2020

I have a question slightly related to this. If you are using LDAP auth and add SMTP info, will it automatically send welcome emails to existing users? Or when new users are automatically pulled into Nextcloud?

@navachaitanya

This comment has been minimized.

@ChristophWurst
Copy link
Member

@skjnldsv that sounds like a good solution. +1

@jancborchardt where should we put this menu?

@nickvergessen
Copy link
Member

We already have the settings menu on the users page (bottom left navigation). You can set a default quota there. Settings the email flag there should be good enough

@ChristophWurst
Copy link
Member

That is what I wanted to go for, but …

Nonetheless, it also break the flow to have this into the bottom left settings area as the new user creation form is on top.

🤷‍♂️

@nickvergessen
Copy link
Member

As this is a one time thing it's good enough?

@ChristophWurst
Copy link
Member

I might also just do it there. Simple reason is that we want to backport it to older versions. And I don't see myself backporting a restructuring of the form.

@ChristophWurst
Copy link
Member

Where should we persist it? System config? User config? Or just locally in the browser?

@arnowelzel
Copy link
Contributor

@ChristophWurst the setting to send emails to new users should be persistet in the system config.

@JB1985
Copy link
Author

JB1985 commented Jul 28, 2020

Wow, thanks it seems the setting to enable/disable Email Welcome Mail to be back.

Great work!

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

Successfully merging a pull request may close this issue.