0

After much wailing and gnashing of teeth, I've got adminer up and running on my Ubuntu 20.04 server running a LEMP stack. The database management seems to work fine, but it looks ugly as sin, without even the default skin on (see screenshot). That would be fine except that it makes it hard to use the program effectively.

I tried putting a new adminer.css file into the directory with adminer.php (see second screenshot), but it didn't work. I've also gone down a lot of rabbit holes here and on sourceforge with no luck. Most of them point to some issue with .css serving through https:// but I don't know enough to make sense of what's happening or not happening.

So I turn to you, great hive mind. What else can I try? Below is my nginx server block for reference:

server {
    server_name adminer.WEBSITE.COM;

    root /var/www/html/adminer;

    index index.php index.html index.htm index.nginx-debian.html

    access_log /var/log/nginx/adminer.access.log;
    error_log /var/log/nginx/adminer.error.log;

    location / {
            try_files $uri $uri/ /index.php?$args;
            include /etc/nginx/mime.types;
    }

    location ~\.php$ {
            auth_basic "Please enter username and password";
            auth_basic_user_file /etc/nginx/PASSWORDFILE;
            include snippets/fastcgi-php.conf;
            fastcgi_pass unix:/run/php/php7.4-fpm.sock;
    }

    listen 443 ssl; # managed by Certbot
    ssl_certificate /etc/letsencrypt/live/adminer.WEBSITE.COM/fullchain.pem; # managed by Certbot
    ssl_certificate_key /etc/letsencrypt/live/adminer.WEBSITE.COM/privkey.pem; # managed by Certbot
    include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
    ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}

server {
    if ($host = adminer.WEBSITE.COM) {
        return 301 https://$host$request_uri;
    } # managed by Certbot

    server_name adminer.WEBSITE.COM;
    listen 80;
    return 404; # managed by Certbot
}

screenshot of my horrible adminer interface screenshot of my adminer directory

F. Müller
  • 3,969
  • 8
  • 38
  • 49
  • I’d start by checking the generated HTML output, whether that actually tries to embed the CSS resource, and then check if there was any error related to loading that using the browser console … – CBroe Aug 14 '20 at 07:44
  • Thanks for the suggestion. In looking at the html, I can see two locations where .css files are referenced `` and `` It doesn't seem like there are any errors. I located both files on my server and tried replacing them with the code from adminer.css and restarting nginx to no avail. – G. Maynard Aug 14 '20 at 12:07

0 Answers0