Yunohost package 404 on admin page after first successful install

Hello all

I have a question about setting up Processwire on Yunohost. I completed setup apparently successfully, but the admin page for Processwire is not accessible at the link the processwire setup completion page lists. ie

mysite.tld ← processwire install
mysite.tld/pw/ ← custom url I specified in setup as admin (the link is broken)

I posted a comment on an issue in the Github YNH Processwire package about this, and it disappeared (!) after a few minutes of being up.

So I have created a new issue on Github and am also posting here in case anyone can help.

Describe the bug

After successful install of processwire, processwire admin page url is broken - receives a 404 nginx error.



  • email YH instance: Remote VPS - Scaleway Stardust Server
  • main YH instance: Old computer - Mac Mini circa 2014 (running on VM via VirtualBox)

YunoHost version: 11.2.3

I have access to my server :

  • Through SSH
  • through the webadmin
  • direct access via keyboard / screen

Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no

Steps to reproduce

  • Install Processwire package on Yunohost - no issues
  • Go to main url where package is installed, and start Processwire setup via web interface
  • Part way through, install requires MySQL details
  • Log in to PHPMyAdmin and check MySQL details ( the database and user is already set up )
  • Manually set MySQL password in PHPMyAdmin
  • Enter details into Processwire setup process
  • Complete processwire setup successfully
  • Completion page shows link to admin page. Go to that link: 404 nginx error instead of admin / login page

Expected behavior

I expected that when I go to the admin link, the admin page appears.

I want to know how to change the nginx settings to make my processwire install work, and/or have the package updated with the correct nginx settings.


The package completed install successfully according to Yunohost, so there are no logs, I think? But please correct me if I am wrong!

Thanks for reading, I hope this helps someone or provides some clues.

Hi nqo,

Strange that your comment on Github disappeared!

I had a look at the package on Github, Eric made some change last week (apparently disabling a mail with admin-instructions during install).

Have you already created a lot of content the past week, or would it be an option to retry the install?

On the other hand, the issue mentioning “Admin 404” is still open, as is an earlier issue regarding a custom URL for admin. Maybe the app is being reworked: almost all files have been changed last week.

1 Like

Hi @wbk,

Thank you for letting me know about the updates to the package. @ericg mentioned he didn’t know how to correct the issue with the package. I did some deep dives into what other people have had trouble with in PW installs for my own troubleshooting, but posted the results somewhere (here or the GitHub repo?). Anyway, hopefully they were helpful!

Yes, I’ll reinstall and see if the issue is resolved.

I didn’t notice the open issue re a custom admin url - thank you for highlighting that. Next time I install, I’ll try the default admin url (I opted for a custom one last time, which could have been part of the issue).

Re my comment on Github disappearing… eh, it may be operator error on my part. :stuck_out_tongue_winking_eye: Perhaps I commented on two different branches? I use GitHub, but badly.

I’ll let folks know how I go with the new Processwire install by posting here.

Hi @wbk and @ericg and all

Update: Reinstall unsuccessful
I uninstalled and re-installed Processwire. The same error persists.

Tips on nginx for Processwire on Yunohost
For folks following along, troubleshooting their own installs, here is where I list the nginx config clues I’ve found so far: [Request] ProcessWire - #5 by nqo

Next steps
I’ll try these:

  • tinker with the nginx config (based on code recommended in link I shared above)
  • try installing a blank Processwire setup via the CustomWebApp package

I’ll let you know how these experiments go.

1 Like

:face_with_monocle: Update: Clue
I installed Processwire via MyWebApp, and received the same error as in the processwire package. This tells me it’s an issue of nginx config for Processwire specifically on Yunohost.

:tada: Update: Success!
Changes in the following files fixed this issue…

Change 1

File path & name: /var/www/processwire/.htaccess
Added this line:

  RewriteBase /var/www/processwire

:point_up: This shouldn’t really matter because nginx ignores it, but I’m listing everything I changed, in case it helps someone else (and perhaps my future self, too). :stuck_out_tongue_winking_eye:

Change 2

File path & name: /etc/nginx/conf.d/mydomain.tld.conf
Current (working) config:

map $http_upgrade $connection_upgrade {
    default upgrade;
    ''      close;

server {
    listen 80;
    listen [::]:80;
    server_name mydomain.tld www.mydomain.tld;

    index index.php index.html;
    root /var/www/processwire;

    charset utf-8;

    # Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
    client_max_body_size 100M;


server {
    listen 443 ssl http2;
    listen [::]:443 ssl http2;
    server_name mydomain.tld www.mydomain.tld;

    index index.php index.html;
    root /var/www/processwire;

    charset utf-8;

    # Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
    client_max_body_size 100M;

    # -----------------------------------------------------------------------------------------------
    # Processwire nginx rules
    # -----------------------------------------------------------------------------------------------

    # Make nginx rewrite rules

    try_files $uri $uri/ index.php;

    # -----------------------------------------------------------------------------------------------
    # Yunohost default rules
    # -----------------------------------------------------------------------------------------------

    include /etc/nginx/conf.d/;

    ssl_certificate /etc/yunohost/certs/mydomain.tld/crt.pem;
    ssl_certificate_key /etc/yunohost/certs/mydomain.tld/key.pem;

    more_set_headers "Strict-Transport-Security : max-age=63072000; includeSubDomains; preload";

    # OCSP settings
    ssl_stapling on;
    ssl_stapling_verify on;
    ssl_trusted_certificate /etc/yunohost/certs/mydomain.tld/crt.pem;
    resolver valid=300s;
    resolver_timeout 5s;

    location ^~ '/.well-known/autoconfig/mail/' {
        alias /var/www/.well-known/mydomain.tld/autoconfig/mail/;

    access_by_lua_file /usr/share/ssowat/access.lua;

    include /etc/nginx/conf.d/mydomain.tld.d/*.conf;

    include /etc/nginx/conf.d/;
    include /etc/nginx/conf.d/;
    include /etc/nginx/conf.d/;
    include /etc/nginx/conf.d/;

    access_log /var/log/nginx/mydomain.tld-access.log;
    error_log /var/log/nginx/mydomain.tld-error.log;

Change 3

File path & name: /etc/nginx/conf.d/
Current (working) contents of this file:

# sub_path_only rewrite ^/$ / permanent;
location / {

  # Path to source
  alias /var/www/processwire/;

  # -----------------------------------------------------------------------------------------------
  # Processwire nginx rules
  # -----------------------------------------------------------------------------------------------

  # Block access to any file or directory that begins with a period
  location ~ /\.(?!well-known).* {
     deny all;

  # If the request is for a static file, then set expires header and disable logging.
  # Give control to ProcessWire if the requested file or directory is non-existing.

  location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|eot|woff|ttf)$ {
    expires 15d;
    log_not_found off;
    access_log off;
    try_files $uri $uri/ /index.php?it=$uri&$query_string;

  # Pass the PHP scripts to FastCGI server on local socket

  location ~ [^/]\.php(/|$) {
    fastcgi_split_path_info ^(.+?\.php)(/.*)$;
    fastcgi_pass unix:/var/run/php/php8.2-fpm-processwire.sock;

    fastcgi_index index.php;
    include fastcgi_params;
    fastcgi_param REMOTE_USER $remote_user;
    fastcgi_param PATH_INFO $fastcgi_path_info;
    fastcgi_param SCRIPT_FILENAME $request_filename;

  # Amplify dashboard
  location /nginx_status {
        stub_status on;
        deny all;

    location = /favicon.ico { access_log off; log_not_found off; }
    location = /robots.txt  { access_log off; log_not_found off; }

    error_page 404 /index.php;

  # Include SSOWAT user panel.
  include conf.d/;

@ericg I am new to contributing code to projects, but if you would like n00b help, I am happy to do tasks to add working a nginx config to the processwire YNH package. Please let me know if you’d like help. :smiley:

Edit: The login page appears, but I have not been able to successfully log in using the details I entered during the Processwire setup :sob:

Edit: I found more information about Processwire nginx config in in this gist: ProcessWire nginx configuration; Based on · GitHub
Currently looking for clues here.
And more potentially useful config here:


This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.