Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2018-03-06 15:31:15

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,912
Website

https barrier to local dev testing on Safari

Since this last Safari update, or so, I’ve not been able to look at any of my local sites on Safari, giving me the “Safari can’t open page” notice because it’s looking for an https. It redirects there no matter what I put in the address bar. I can’t seem to figure out how to skirt this. No such problem in Firefox.

Anyone know what to do besides a needless setup of https on a local server? Which I wouldn’t know how to do anyway.

Offline

#2 2018-03-06 15:47:55

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,564
Website GitHub Mastodon

Re: https barrier to local dev testing on Safari

It’s due to the way macOS handles .dev domains now (it forces the browser to HTTPS protocol) which I assume you are currently using? You’ll get the same results on latest Firefox Dev Edition and Chrome too.

If you change all your local development sites to use the .local domain instead, you can continue to use HTTP protocol for that.

Offline

#3 2018-03-06 15:53:03

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,912
Website

Re: https barrier to local dev testing on Safari

Ah! I should have picked up on that. Yep, time to change.

I’m pretty sure even .local is a special-use domain now too. Or maybe it’s .localhost? Yep, both. And .test.

Anyway, thanks!

Offline

#4 2018-03-06 15:55:04

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,564
Website GitHub Mastodon

Re: https barrier to local dev testing on Safari

And here’s why (your old friend Google is to blame)

(although ignore the TLD recommendations in that article, .local is pretty standardised across the industry)

Offline

#5 2018-03-06 16:15:09

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,912
Website

Re: https barrier to local dev testing on Safari

Never noticed Safari’s Develop > Enter Responsive Design Mode before. That’s sweet.

Offline

#6 2018-03-06 16:17:52

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,564
Website GitHub Mastodon

Re: https barrier to local dev testing on Safari

Have you tried Firefox Developer Edition recently? It’s rocks! My go-to choice for in-browser dev work nowadays.

Offline

#7 2018-03-06 17:16:58

michaelkpate
Moderator
From: Avon Park, FL
Registered: 2004-02-24
Posts: 1,379
Website GitHub Mastodon

Re: https barrier to local dev testing on Safari

I had never of heard of using .dev domains. And now it seems like I missed out.

A week ago, I didn’t even know .dev was a real gTLD. Historically it’s just been the realm of programmers who need a fake domain for testing. The domain never really existed, we just told our computers to pretend it does.

But the .dev gTLD does exist. And guess who owns it?

That’s right.

It’s Google.

Use a .dev domain? Not anymore.

I have playing around at home the last few days setting up an environment to do web stuff. After watch some stuff on YouTube, I ended up settling on Xubuntu and Atom.

I then had the idea of installing Webmin and Virtualmin to be able to setup virtual domains. I never could get them to work like I wanted because of DNS issues.

Offline

#8 2018-03-06 21:36:06

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,730
Website

Re: https barrier to local dev testing on Safari

Yes, I was surprised when .dev stopped working for me despite being set in the etc/hosts file.

But .test does work for me as a local development TLD.

And you can, of course, use dev.mydomain.com and then switch it to www. (or none) when you’re ready to go live. You just need to intercept with the etc/hosts file (or MAMP and co does it for you).


TXP Builders – finely-crafted code, design and txp

Offline

#9 2018-03-06 21:42:35

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,263
GitHub

Re: https barrier to local dev testing on Safari

Destry wrote #309699:

Never noticed Safari’s Develop > Enter Responsive Design Mode before. That’s sweet.

Open Terminal, and type this:

defaults write com.apple.Safari IncludeInternalDebugMenu 1

Voila, you now have a Debug menu. Run that command again with 0 instead of 1 and it’ll disappear.

Last edited by gaekwad (2018-03-06 22:26:40)

Offline

#10 2018-03-06 21:45:23

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,263
GitHub

Re: https barrier to local dev testing on Safari

jakob wrote #309705:

You just need to intercept with the etc/hosts file (or MAMP and co does it for you).

I use Gas Mask for macOS hosts management, does the job very well.

Offline

#11 2018-03-06 22:20:16

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,912
Website

Re: https barrier to local dev testing on Safari

jakob wrote #309705:

But .test does work for me as a local development TLD.

That’s what I switched to as well. Working fine.

Offline

#12 2018-03-07 16:59:27

bici
Member
From: vancouver
Registered: 2004-02-24
Posts: 2,092
Website Mastodon

Re: https barrier to local dev testing on Safari

gaekwad wrote #309707:

I use Gas Mask for macOS hosts management, does the job very well.

wow. i had never heard of it. i have been using MAMP Pro.


…. texted postive

Offline

Board footer

Powered by FluxBB