Breaking change on mailer configuration in Joplin Server 2.7

This is just to let you know that there may be a breaking change in the mailer configuration in the next Joplin version 2.7. In particular:

  • MAILER_SECURE has been renamed to MAILER_SECURITY and can now have the value "tls", "starttls" or "none"
  • And the default value for MAILER_PORT is now 465 (instead of 587 previously)

The previous configuration default values were somehow broken and wouldn't work by default so it's possible it's not even a breaking change but I thought I'd mention it anyway.

If the values are wrong, the server will tell you so on startup, and emails that can't be sent will be queued for later, so there won't be any major impact.

More info in this pull request:

1 Like

Thank you for the heads up! I’ll check my config tomorrow.

Edit: just checked. Will the MAILER_SECURITY take only these three settings or also a boolean?

Only these three values. You basically choose what encryption mode to use or none at all.

I have noticed that the compressed docker image size (of the official x86_64 image) from 2.7.3 to 2.7.4 has dropped from 1.32GB to just 294.73MB.

Has the docker image really been reduced by 80%?

EDIT: Just to explain, I use an ARM version that is created automatically by a third party. This will not run and trying to view logs throws up exec errors. I am trying ascertain if it is the conversion or the source itself that is having a bad day. I am not currently in a position to pull the official image on an x86_64 machine to check.

While I can't say whether it is or isn't the cause, I'd created a Snap image of the server in the past as low as 150MB, so IMO there's huge gains that could be had for filesize vs the previous releases of the image, ~300MB doesn't seem unlikely at all.

I've just installed it and it seems to work fine. We've improved how the image is built and changed the base image.

Yes it's likely the issue is with the ARM version as they probably need to update the build steps since the Dockerfile has changed a lot.

1 Like

When can we expect the .4 release in the :latest branch?

@dpoulton @laurent

standard_init_linux.go:228: exec user process caused: exec format error

I'm actually using the upstream Dockerfile.server file to conduct the build. I've identified the issue. It's due to the way tini is being downloaded/installed. It's explicitly downloading the amd64 version (this is not compatible with armv7 or arm64). I created an issue and verified a fix. The new images are pushed up to Docker Hub if anyone wants to test (works for me).

Issue: https://github.com/laurent22/joplin/issues/6096
PR: https://github.com/laurent22/joplin/pull/6097

1 Like

What is Joplin Server using emails for? I can't find any documentation for it at all.

User account verification, for one.

@cottage45

There are some .env settings that are pretty much only useful if you are managing multiple users or Joplin Cloud itself. The only reason I ever turned some of them on was for beta testing before Joplin Cloud went live.

There is a thread which has some discusssion about the mail server and makes reference to the config.ts file which shows a list of .env variables that can be used. Note that this is an older version of the file and makes reference to MAILER_SECURE which has been replaced by MAILER_SECURITY.

Some of the .env variables are:

MAILER_ENABLED= Enables the mailing system - 1 is ON 0 is OFF
MAILER_HOST= SMTP server address
MAILER_PORT= SMTP server port
MAILER_SECURITY= SMTP server security method - none or tls or starttls (Server 2.7.4 and above)
MAILER_AUTH_USER= Login username for the SMTP server
MAILER_AUTH_PASSWORD= Login password for the SMTP server
MAILER_NOREPLY_NAME= Display name for mail sent by the server
MAILER_NOREPLY_EMAIL= Sender email address for mail sent by the server
SIGNUP_ENABLED= Enables site visitors to sign up from the server login page - 1 is ON 0 is OFF (I have not used this since before Joplin Cloud went "Live")
TERMS_ENABLED= Enables the login page terms and conditions link - 1 is ON 0 is OFF (I have not used this as anything other than "OFF" since before Joplin Cloud went "Live")
ACCOUNT_TYPES_ENABLED= Enables the admin to set user accounts as Default, Basic or Pro with their associated usage limits / sharing features - 1 is ON 0 is OFF

There are some others such as USER_CONTENT_BASE_URL= but the last time I looked at a more recent version of the config.ts file this was commented as not being in use. Others appear to be specifically Joplin Cloud related.

2 Likes

For the env variables a more recent reference would be env.ts. I've set it up so that it's more or less self-documenting with the value type and default values being visible directly in this file.

2 Likes

@etho201

ARM image for 2.7.4 works for me as well. Thank-you for maintaining this.

I try again.. :slight_smile:

I see that the latest Joplin Server here: Joplin Server Changelog | Joplin is 2.7.4. However, using the :latest tag in Docker Compose, I can’t seem to upgrade to said version (no new version is found when I try). Am I doing something wrong or it is simply not tagged as the latest in the Docker repository?

People here seem to be using it, I don’t want to be left out. :smiley:

Edit: it became available just about now, thank you! Also reconfigured the mail-related changes, everything works great.

@anon33605855

At the time of writing Laurent appears to have tagged server v2.7.4 as :latest 15mins ago, so you will now get v2.7.4 if you pull using the :latest tag.

With the official server images they are released as a series of betas. Later, when one is considered fit to be a release, it is further marked :latest. So with the official images :latest == latest stable release. There may be newer betas.

So if you want the latest stable server version use joplin/server:latest. If you want the newest version use joplin/server:beta.

It's a bit different for us using third-party ARM versions as there the tag :latest tends to mean the newest version, beta or not.

Thanks, but I I've edited my comment, saying I was able to update, also thanks for the info but I know how this works, I was just missing the tagging of the latest version (hence I've also said I couldn't see this version at the :latest). :slight_smile:

I was just pointing out for future reference that with the official images :latest != newest.

Thanks but I'm aware of that. As it is, I have to work with docker (and various other container technologies, as well) in my professional life so I have a slight knowledge of it, unfortunately. :slight_smile: