I just created a Vaultwarden + Caddy docker in WSL2 from Windows 11.
After initial log on and creating master password I clicked on the Send Email of Verify Email prompt. I have never received the email sent by Vaultwarden.
The error message InvalidUser points to the local part of the mail address (either in the to: or from:) being wrong.
My guess would be that the quotation marks around the values of the SMTP_FROM environment variable are causing issues as they seem to be “ and ” and not just " and thus the value is set to “zung25@gmail.com” instead of zung25@gmail.com
You can check in the /admin page and verify if the SMTP configuration is correct.
I have resolved the issues. I think the restart from Docker Desktop did not pick up the updated docker-compose file. I used docker command to down and up the containers and it worked fine now.
As an aside, I would HIGHLY recommend that you change your current Gmail SMTP app password as you appear to have posted it here (as well as your login credentials) unredacted in a public forum (possibly also edit your posting here, but assume it’s already compromised).
Delete the current one you are using and then create another as discussed below.
Even with 2FA on your Google account, this app password bypasses this for SMTP.
While I don’t think (hope) anyone here would use it nefariously, but this is again a public forum open to the internet and anyone can stumble upon this.
Generally good opsec would advise not to have any of your credentials in the clear.
The same would go for your ADMIN_TOKEN while not sure if your host is publicly available again this is the credential for access to the Admin panel.
So best to change this and keep it closely guarded as well.
Best