Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dns-prefetch-check failing www.google-analytics.com #133

Open
flvyu opened this issue Jun 12, 2020 · 9 comments
Open

dns-prefetch-check failing www.google-analytics.com #133

flvyu opened this issue Jun 12, 2020 · 9 comments

Comments

@flvyu
Copy link

flvyu commented Jun 12, 2020

I did not make any changes to the links in the site, but started seeing this error.

✖ FAIL dns-prefetch-check www.google-analytics.com

expected: DNS exists www.google-analytics.com
actual: self signed certificate
at: public/404.html:1:6092 <link rel="preconnect dns-prefetch" href="https://www.google-analytics.com">
@AnnieTaylorCHEN
Copy link

AnnieTaylorCHEN commented Jun 25, 2020

I have exactly the same errors:

✖ FAIL dns-prefetch-check www.google-analytics.com
5:00:53 PM:   | operator: dns-prefetch-check
5:00:53 PM:   | expected: DNS exists www.google-analytics.com
5:00:53 PM:   |   actual: self signed certificate
5:00:53 PM:   |       at: public/404.html:1:22575 <link rel="preconnect dns-prefetch" href="https://www.google-analytics.com">

Anyone knows how to fix this? Installed the plugin from netlify UI, so I didn't do any manual configuration.

@sachinsancheti1
Copy link

me too

@sykaeh
Copy link

sykaeh commented Jan 9, 2021

I get a similar error for Google Fonts:

11:39:36 PM:   ✖ FAIL preconnect-check https://fonts.gstatic.com
11:39:36 PM:   | operator: preconnect-check
11:39:36 PM:   | expected: connection accepted https://fonts.gstatic.com
11:39:36 PM:   |   actual: self signed certificate
11:39:36 PM:   |       at: build/index.html:1:589 <link rel="preconnect" href="https://fonts.gstatic.com">

@BenColwell131
Copy link

Did you find a solution for this?

@sykaeh
Copy link

sykaeh commented Jan 14, 2021

I haven't looked into a fix for this, but I used this workaround for the moment (in the netlify.toml File):

[[plugins]]
  package = "netlify-plugin-checklinks"

  [plugins.inputs]
    skipPatterns = ['https://fonts.gstatic.com']

You can probably use the same workaround for www.google-analytics.com

@BenColwell131
Copy link

BenColwell131 commented Jan 14, 2021 via email

@AnnieTaylorCHEN
Copy link

I haven't looked into a fix for this, but I used this workaround for the moment (in the netlify.toml File):

[[plugins]]
  package = "netlify-plugin-checklinks"

  [plugins.inputs]
    skipPatterns = ['https://fonts.gstatic.com']

You can probably use the same workaround for www.google-analytics.com

I just tried this fix, replacing it with google analytics and it worked like a charm! Thanks!

@mfanuzzi
Copy link

I've had this issue as well when adding google fonts to preconnect:

  ✖ FAIL preconnect-check https://fonts.googleapis.com
  | operator: preconnect-check
  | expected: connection accepted https://fonts.googleapis.com
  |   actual: self signed certificate
  |       at: public/404.html:1:5071 <link rel="preconnect" href="https://fonts.googleapis.com" crossorigin="true">
  
  ✖ FAIL preconnect-check https://fonts.gstatic.com
  | operator: preconnect-check
  | expected: connection accepted https://fonts.gstatic.com
  |   actual: self signed certificate
  |       at: public/404.html:1:5150 <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="true">

Initially I thought this had something to do with them not being in our default content security policy (Gatsby) but I've added them and no change. No console errors on the actual site in use so just limited to the plugin.

Adding "https://fonts.gstatic.com", "https://fonts.googleapis.com" to skipPatterns works but I wonder if this is the recommended approach @Munter? Is google really using a self-signed cert here?

@Munter
Copy link
Owner

Munter commented Mar 22, 2022

@mfanuzzi I doubt that Google is using a self-signed certificate. I would say it's more likely that some random network error or intercept is occurring, or that the netlify runner is a container with outdated root-level certificates. None of those are issues I can really do anything about.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants