How do I Change Email Adress in admin/settings/emails?

I had a certified Discourse Support person help us changing Discourse servers, and after that, Discourse did not send out automated emails anymore. I checked the error-log and it told me to contact Sendingblue to activate SMTP, which I did (and they activated it):

However, it still didn’t work, so I found that under admin/settings/emails, the Discourse Support person’s email was listed instead of my email:

I have tried to reach this support person for almost two weeks, but he is not answering his emails, and I can’t reach him on any of his platforms. How do I change his email address to mine?

Thank you very much!
Wes

If yours is a standard install, that address is set in your app.yml. So you can either edit the app.yml directly, or run ./discourse-setup again to put your correct SMTP details in. If you go to your mail provider that should have the username and password details you need. :+1:

If you need more detail, it’s this section of the guide.

Thanks for your reply, Jammy! I don’t have an app.yml in my console, so that leave me to run discourse-setup, I guess. I am so not technical, so I apologize for any silly questions here. But I want to make sure I don’t mess up.

If I run discourse-setup, as you suggested, does that create a completely new install, or is it just changing the SMTP info? I can’t manually back up Discourse because the email function is not working. So, dare I do this without backing up Discourse first, you think?

If Jammy is not available, please feel free to reply, anyone…

I completely understand. :slightly_smiling_face: It can feel a bit nervy doing the backend stuff versus the admin console.

Just to check, do you have access to your server (self-hosted), or are you using a hosting provider? If you don’t have access to your server you may need to contact whoever is hosting your site to make these changes.

If you have access to your server, I think the safer option is to re-run ./discourse-setup as you’re less likely to make a typo outside of the data you’re entering. It won’t double up your live instances, and is fine to run multiple times. :+1:

You can refer to the Troubleshoot email on a new Discourse install guide for more info as well.

And you can also take a back-up from the command line, if you want to be prudent.

Do you want to have a read through of those and see if you have any questions before you get started?

2 Likes

Thank you, Jammy. I’ll be back. There is another tech support rep looking into it now. I’ll see what he can do. I’ll be back here regardless. Appreciate your helpfulness!

2 Likes

I have never done this before, so please bear with me. I am trying to back it all up using the link you gave me: Backup discourse from the command line .

So, now I’m in ./launcher (see photo).

This is what it says in the link above:

Enter the container:

./launcher enter app

Run the backup:

discourse backup
exit

This will print out the final filename of your backup. Download the backup and container configuration (if needed) to your local machine:

scp root@69.55.54.86:/var/discourse/shared/standalone/backups/default/the-wes-penre-discussion-board-2022-03-15-152304-v20220228163400.tar.gz	 .
scp root@69.55.54.86:/var/discourse/containers/app.yml .

I have no idea how to do this. I have the launcher window up. What do I do next? How and where do I run the backup, etc.?

I’m afraid I’m unfamiliar with WinSCP. I’ve downloaded and set it up it now, but I won’t get a chance to look at it properly until later.

If you can SSH into your server using something like Windows powershell, or even the ‘access console’ option if you’re with Digital Ocean, then I can probably help you quicker. :slightly_smiling_face:

Yes, I have the console option available to me in Digital Ocean (DO from here on). Launch droplet console, it says…

Brilliant. :slightly_smiling_face::+1:

Launch droplet console

Then cd /var/discourse.

Then ./launcher enter app (give it a second)

Followed by discourse backup (this can take a moment to kick in too)

And then exit once it’s done


I think the instructions for a lot of these things will make more sense now you’ve gone through the console rather than WinSCP. :crossed_fingers:

1 Like

This seems so much easier! Now, everything went fine until I entered, discourse backup . It says ‘command not found.’

And I’ve entered it with a space between discourse and backup.

I should have done this:

I don’t have the data.yml apparently.

Ah, it looks like you have a two-container set-up.

Let me just double check which one we want to amend.

1 Like

You want to do this:

cd /var/discourse
./launcher enter web_only
discourse  backup

When you go to get the data with winSCP you’ll look in /var/discourse/shared/web-only/backups/defau/t (unless it’s web_only, but I think it has the dash there).

At some point you’ll need to rebuild your data container like this:

./launcher rebuild data
./launcher bootstrap web_only && launcher destroy web_only; ./launcher start web_only

(If you haven’t updated the container with docker_manager from the web interface, you can replace the rebuild with stop, but it mostly never hurts to bootstrap.

The rebuild will also make sure that you’re on the main and not master branch and do a git pull.

3 Likes

That’s brilliant. Thank you @pfaffman :+1::slightly_smiling_face: I’m afraid I don’t have any practical experience with the two-container set-up yet, so seeing your avatar typing away at the bottom was a relief indeed. :slightly_smiling_face:

Would running ./discourse-setup --two-container be the alternative for a two-container set-up? I wasn’t sure if you could run that multiple times like the regular one?

And if not, would it be this to update the SMTP details?

cd /var/discourse 
nano containers/web_only.yml

1 Like

No. But if you run discourse-setup after an installation it’ll notice if there is a web_only and do the Right Thing :tm:. (If you have both app and web_only, then it’ll ignore one of them).

1 Like

Wow! Indeed brilliant. Thank you so much, Jay! It’s working. It’s downloading to my computer now. This is a great workaround when I don’t have email smtp set up.

Thanks also, Jammy! I’ve learned something new here. I need to learn this whole thing, one thing at the time. Discourse is such a neat program, and I love it! I just needs to learn what’s under the hood. I still need to understand how to change the email address for smtp, but I’ll follow the instructions I’ve gotten so far, and if I have more questions, I come back here…

2 Likes

Just in case it got lost in the back and forth, now you have your backup you should be able to do:

cd /var/discourse
./discourse-setup

And fill your SMTP details in the prompts in there. :+1:

1 Like

Just run discourse-setup.

2 Likes