Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Docker image no longer starts if you set SYNAPSE_SMTP_HOST #5430

Closed

Description

@richvdh

As far as I can tell, the SYNAPSE_SMTP_* settings were never used, because email_notifs was set to false in the homeserver.yaml used by the docker image. Nevertheless the documentation kinda encourages you to set the SYNAPSE_SMTP_* settings. Those that did so will now find that their servers refuse to start, with:

RuntimeError: email.password_reset_behaviour is set to 'local' but no public_baseurl is set. This is necessary to generate password reset links

Activity

  1. richvdh commented on Jun 11, 2019

    @richvdh
    MemberAuthor

    The workarounds for now are either:

    • don't set the SYNAPSE_SMTP_* env vars (will disable password reset on your server)
    • use a custom config file via SYNAPSE_CONFIG_PATH
  2. added
    A-DockerDocker images, or making it easier to run Synapse in a container.
    on Jun 13, 2019
  3. anoadragon453 commented on Jun 21, 2019

    @anoadragon453
    Member

    A quick fix before figuring out the whole Docker mess is just to add a SYNAPSE_PUBLIC_BASEURL environment variable. This behaviour has been implemented in #5519.

    But we should really figure this out :/

  4. richvdh commented on Jun 21, 2019

    @richvdh
    MemberAuthor

    I'm not convinced adding a SYNAPSE_PUBLIC_BASEURL is the best approach.

    We're going to be telling people to switch to the SYNAPSE_CONFIG_PATH approach, so rather than having them add a SYNAPSE_PUBLIC_BASEURL, I think we should tell them to switch to a generated file.

    The only question is whether we can do something better for people whose working configs have been broken by 1.0, like disabling password resets altogether?

    Given the SYNAPSE_SMTP_ vars are unused in synapse <0.99, maybe we should just remove them, and skip generating the email config section?

  5. richvdh commented on Jun 21, 2019

    @richvdh
    MemberAuthor

    (incidentally it might be good to do that against the release branch and we can update the docker image on dockerhub.)

  6. anoadragon453 commented on Jun 24, 2019

    @anoadragon453
    Member

    Given the SYNAPSE_SMTP_ vars are unused in synapse <0.99, maybe we should just remove them, and skip generating the email config section?

    This sounds best to me, considering, as you say, they were never actually used.

  7. hawkowl commented on Jun 25, 2019

    @hawkowl
    Contributor

    Because of #5518, I believe we can say "use a proper config" here, and close it?

  8. richvdh commented on Jun 25, 2019

    @richvdh
    MemberAuthor

    Because of #5518, I believe we can say "use a proper config" here, and close it?

    As per #5430 (comment): I'd prefer not to break peoples' working configs, and I think we can do better.

  9. xobs commented on Jul 3, 2019

    @xobs

    The README.md on https://hub.docker.com/r/matrixdotorg/synapse still documents those variables, so that should first be removed prior to closing this issue.

  10. richvdh commented on Jul 3, 2019

    @richvdh
    MemberAuthor

    the readme will be updated at the same time as the docker image is updated on hub.docker.

    fixed by #5596

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-DockerDocker images, or making it easier to run Synapse in a container.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions