Sidekiq shows activation emails being sent to email address nil

I can give you the exact process I used. Perhaps something in the process I am doing is wrong. I’m willing to totally accept I’m making a mistake somewhere!

  1. Have domain. It is discourse.domain.dev (domain obviously redacted)
  2. Have an email account setup. I have a mailgun account, so I set up a brand new user for SMTP. The email is discourse@discourse.domain.dev
  3. Have server. It’s the latest Ubuntu (Jammy Jellyfish)
  4. apt install docker.io - None
  5. Git was already installed
  6. user was root
  7. cloned using git clone https://github.com/discourse/discourse_docker.git /var/discourse
  8. navigated to cd /var/discourse
  9. chmod 700 containers
  10. still root user
  11. ran ./discourse-setup
  12. Filled in info as requested: discourse.domain.dev
  13. Discourse Admin Email: my@personal.email
  14. SMTP: smtp.eu.mailgun.org
  15. SMTP PORT: 587
  16. username: noreply@discourse.domain.dev
  17. userpass: REDACTED
  18. notification email: noreply@discourse.domain.dev
  19. Lets encrypt email: my@personal.email
  20. Maxmind ID: Put it in
  21. Max Mind License: Put it in
  22. Verified the input data for the setup.
  23. Pressed Enter.
  24. Waited.
  25. Waited some more
  26. Made a cuppa
  27. Last line of the bootstrap process:
    + /usr/bin/docker run --shm-size=512m -d --restart=always -e LANG=en_US.UTF-8 -e RAILS_ENV=production -e UNICORN_WORKERS=8 -e UNICORN_SIDEKIQS=1 -e RUBY_GC_HEAP_GROWTH_MAX_SLOTS=40000 -e RUBY_GC_HEAP_INIT_SLOTS=400000 -e RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=1.5 -e DISCOURSE_DB_SOCKET=/var/run/postgresql -e DISCOURSE_DB_HOST= -e DISCOURSE_DB_PORT= -e LETSENCRYPT_DIR=/shared/letsencrypt -e DISCOURSE_FORCE_HTTPS=true -e LC_ALL=en_US.UTF-8 -e LANGUAGE=en_US.UTF-8 -e DISCOURSE_HOSTNAME=discourse.domain.dev -e DISCOURSE_DEVELOPER_EMAILS=my@personal.email -e DISCOURSE_SMTP_ADDRESS=smtp.eu.mailgun.org -e DISCOURSE_SMTP_PORT=587 -e DISCOURSE_SMTP_USER_NAME=noreply@discourse.domain.dev -e DISCOURSE_SMTP_PASSWORD=b7fc73b0905b5ffb5f70300f1f796000-1b5736a5-0a60075a -e DISCOURSE_SMTP_DOMAIN=discourse.example.com -e DISCOURSE_NOTIFICATION_EMAIL=noreply@discourse.domain.dev -e LETSENCRYPT_ACCOUNT_EMAIL=my@personal.email -e DISCOURSE_MAXMIND_ACCOUNT_ID=REDACTED -e DISCOURSE_MAXMIND_LICENSE_KEY=REDACTED -h devsite -e DOCKER_HOST_IP=172.17.0.1 --name app -t -p 80:80 -p 443:443 -v /var/discourse/shared/standalone:/shared -v /var/discourse/shared/standalone/log/var-log:/var/log --mac-address REDACTGED local_discourse/app /sbin/boot REDACTEDLONGSTRING
  28. Ran ./discourse-doctor. It failed because it could not connect to redis.
  29. Ran ./laucher rebuild app and changed nothing in the config
  30. It built. All ok. The only difference was the last redacted long string.
  31. Ran ./discourse-doctor. I recieved the test email from it.
  32. The site was up so went to create user account for the admin.
  33. Clicked Register
  34. It said that it was sending a notification email.
  35. None recieved.
  36. Checked through ./discourse-docter and saw this:
    Discourse version at discourse.domain.dev: NOT FOUND Discourse version at localhost: NOT FOUND
  37. Ran ./launcher enter app
  38. Ran rake admin:create
  39. Put email: my@personal.email
  40. Reset Password as user already exists
  41. Told “Your account now has Admin priviledges!”
  42. Logged in to site at the domain
  43. Go to discourse.domain.dev/logs - see "Sidekiq heartbeat test failed, restarting`
  44. Go to discourse.domain.dev/sidekiq: See:
  45. Go to view Enqueued
  46. Click on “critical” and expand content and see “to_address”=>nil again.

Stop, and reach out.

This is a complete redo on a new machine today. These are the EXACT same steps I used before. Please, if I messed up, let me know! :pray:


System Setup:

  • CPU: 4 Cores
  • RAM: 16 GB
  • OS: Ubuntu LTS 64bit 24.04
  • Storage: NVMe 500G
  • Postgres Version: 13.16-1
  • Redis: 7.0.7
  • Ruby: 3.3.4
1 Like