Mjs-warning after Nextcloud Update

Dear Community

My Nexcloud runs in a Docker-Container on an Ubuntu 22.04 Server behind an NGINX-ReverseProxy.
I’m using the docker-image nexcloud:latest, so i think i’m using apache (Sorry, i don’t know, where i can find this information…).
PHP version is 8.2.15
After the Update to 28.0.2, i’m facing the following warning in the system overview:

Could not check for JavaScript support. Please check manually if your webserver serves `.mjs` files using the JavaScript MIME type.

I found on Google a lot of information, but nothing matches my environment…
I think, i have to add the .mjs type to a configuration, but i’m not sure where… Should i add it to my nginx-reverseproxy or to my nexcloud apache?
Can anyone help me with an exact step-by-step manual?

Thanks in advance!

I found in the .htaccess-file in the nexcloud-root the following entry:

AddType text/javascript js mjs

So i think, the apache-config is ok and i have to add an entry in the ngnix-proxymanager. But where and how?

1 Like

In this case, your issue isn’t that .mjs files aren’t functioning (well, they still may not be, but…), but that the check to see if they’re functioning (which was recently added) isn’t working in your environment for some reason.

The check just tries to download a specific file via each of your configured trusted_domains from the Nextcloud Server itself. If the check is failing it’s usually something like:

  • DNS is broken in your Nextcloud container
  • You’re using a self-signed certificate

What happens when you run curl -I https://DOMAIN/apps/settings/js/esm-test.mjs from within your Docker container?

1 Like

Thanks for your answer!
I entered the container with this command:

sudo docker exec -it nextcloud-app-1 bash

Then i ran the curl command to my trusted Domain:

curl -I https://cloud.mydomain.tld/apps/settings/js/esm-test.mjs

This was the result:

curl: (28) Failed to connect to cloud.mydomain.tld port 443 after 130860 ms: Couldn't connect to server

To test, i ran the same command from my docker-host, with the same result.
If i ping cloud.mydomain.tld i recieve an answer from my public ip. So, i think dns works ok…

Do you have any ideas how to resolve the problem?