Fresh install doesn't work - missing js [SOLVED]


I saw many people who have the same problem but not found the answer.

I did a fresh install (tried GUI and CLI through occ) and some files are missing


This prevents me to log in

I’ve copied them in

cp /var/www/htdocs/nextcloud/data/appdata_ocee1vaiac6l/js/core/merged-template-prepend.js /var/www/htdocs/nextcloud/js/core/
cp /var/www/htdocs/nextcloud/data/appdata_ocee1vaiac6l/js/core/merged-login.js /var/www/htdocs/nextcloud/js/core/

And I have been able to log in anyway just after login I have other missing files css and js

I’d like to know what is wrong.

I use the Nginx configuration from
I double checked, triple checked, quadruple checked…

The important stanza should be this one

location ~ \.(?:css|js|woff2?|svg|gif|map)$ {
        try_files       $uri /index.php$request_uri;
        #add_header                Cache-Control "public, max-age=15778463";
        #add_header                X-Content-Type-Options nosniff;
        #add_header                X-XSS-Protection "1; mode=block";
        #add_header                X-Robots-Tag none;
        #add_header                X-Download-Options noopen;
        #add_header                X-Permitted-Cross-Domain-Policies none;
        add_header              Referrer-Policy no-referrer;
        # Optional: Don't log access to assets
        access_log      off;

and I put it below

location ~ ^\/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+)\.php(?:$|\/) {

… }
location ~ ^/(?:updater|oc[ms]-provider)(?:$|/) { try_files $uri/ =404; index index.php; }

I tried to disable all modules without any success

Anyone has a solution ?

Are you getting the packages from source or from an OS package manager?

Hello Stratacast,
From source.

When I display the source code of the login page I have

<link rel="stylesheet" href="/css/core/b583-9111-server.css?v=db81cddf52fdb3c8ca1e4c859e214124-7df0e9e4-0">
<link rel="stylesheet" href="/css/core/b583-9111-css-variables.css?v=db81cddf52fdb3c8ca1e4c859e214124-7df0e9e4-0">
<link rel="stylesheet" href="/apps/files_pdfviewer/css/style.css?v=35c36e89-0">
<link rel="stylesheet" href="/css/notifications/12a4-9111-styles.css?v=db81cddf52fdb3c8ca1e4c859e214124-12a43319-0">
<link rel="stylesheet" href="/css/core/b583-9111-results.css?v=db81cddf52fdb3c8ca1e4c859e214124-7df0e9e4-0">
<link rel="stylesheet" href="/css/files/39b9-9111-merged.css?v=db81cddf52fdb3c8ca1e4c859e214124-39b92f95-0">
<link rel="stylesheet" href="/css/activity/062a-9111-style.css?v=db81cddf52fdb3c8ca1e4c859e214124-062af747-0">

And all the files with a name such as …b583-9111… or …39b9-9111… etc. are not available code 404. Files that have a normal path are accessible.

This problem is solved.
I had another nginx css stanza in the begining of the configuration that was intercepting the requests.

location ~* .(jpg|jpeg|png|gif|ico|css|js)$ { expires 30d; }

Man I got busy that day and forgot to check back :slight_smile: I’m glad you figured it out