I’ve been trying to do everything as displayed in the ‘SSL Certificate on macOS’ guide (SSL Certificate on macOS - Local), but once I open the shell, the ‘wp search-replace’ doesn’t work. Can somebody help me sort this out please?
What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc
Security Reminder
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.
The problem is this: when I click onto ‘Open Site’ from Local, there is no SSL (no https:// at all). I don’t know if this is normal because I am new to this. Thanks in advance to anyone could help me!
No errors at all, just when clicking onto Open Site in Local (just right to the WP Admin button) it opens the site without ‘https://’. Maybe it is normal but I don’t know.
This is an old known issue depending on if you are running nginx or Apache. If you have changed the Wordpress and Site address to https and the certificate in the Keychain app it “should” work. But for Apache sites I have added a https redirect in the htaccess file. There are several posts here about this problem and I’ll try to dig up some links.
# BEGIN Redirect to https
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteCond %{SERVER_PORT} !^443$
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
# END Redirect to https
Here is an old post about the same issue. But for me Open Site works now with both nginx and Apache sites. I don’t know if there have been any changes lately in the Local app though.
Thank you everyone, maybe it is a bit too advanced for me. The site runs with nginx but I still have that problem when opening it via the “open site” button. I don’t know why, but as I said, maybe it has to be this way. I’ve done everything as shown in the two previous images.
Thank you for that @emmtre I had forgotten about that bug. It seems like that could be at play here for sure but I would think they should still be able to access Site Shell and perform basic functions there yeah? I haven’t seen anyone mention that being an issue.
Yeah, that’s strange. I would start by checking the WP-CLI installation with the usual commands like which wp and wp --info. And post the output when launching the shell.
You can see some suggestions from emmtre above here. If you’re still having trouble you might also try a full reinstall to refresh here in case something has been corrupted.
Export any sites that you have on Local and save them to a folder somewhere on your computer: Backup a Local Site - Local
Fully uninstall Local from your computer with the steps for your specific OS here: Uninstall Local - Local
Install the latest version of Local on this link: Releases - Local
Once installed, please restart the computer.
When the computer is restarted and turned on, close any applications that automatically run in the background (AntiVirus, Firewall, and other Developer applications included).
The Bug is still open but I’m not 100% sure that is the same issue you are facing here. That’s why I suggested potentially doing a full reinstall here.
Is there anything else unique about your device or connection? Is your device issued by an employer, or do use it with an employer network, proxy, or VPN?
Not at all, it is my personal MacBook and I just use a normal internet network. I really don’t know what’s going on because the only problem is with the Open Site button that always opens without SSL. The WP Admin works perfectly fine.
If that’s the only issue you have now then it may be related to the bug above, but what I was trying to dig into was your Site Shell CLI issues. Are you still running into problems there?