Head’s up! Local’s router is having trouble trouble starting

Hey @Bigroman – It looks like in the Local log there are a number of lines that look like this:

{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"nginx: [alert] could not open error log file: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:48.687Z"}
{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"2021/12/09 20:57:48 [emerg] 3642#0: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:48.694Z"}
{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"nginx: [alert] could not open error log file: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:49.212Z"}
{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"2021/12/09 20:57:49 [emerg] 3644#0: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:49.250Z"}
{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"nginx: [alert] could not open error log file: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:49.772Z"}
{"thread":"main","class":"Process","process":"nginx","level":"warn","message":"2021/12/09 20:57:49 [emerg] 3652#0: open() \"%%router.runPath%%/nginx/logs/error.log\" failed (13: Permission denied)","timestamp":"2021-12-09T19:57:49.792Z"}

Note this part:

nginx: [alert] could not open error log file: open() \"%%router.runPath%%/nginx/logs/error.log

I think that means that for some reason, the permissions of Local Router are set in a way that Local can’t start that process.

Since this is a mac, can you investigate what the permissions of that folder are? The easiest way is using a terminal and running this command:

ls -alh ~/Library/Application\ Support/Local/run/router/nginx/logs/

Here’s what I get for my Mac:

If you have a different value than your username, or if that folder doesn’t exist, then you’ll want to create that folder and have it be owned by your user so that Local can reference and use that error log!