{"action":"created","issue":{"url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/3980","repository_url":"https://api.github.com/repos/gatsbyjs/gatsby","labels_url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/3980/labels{/name}","comments_url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/3980/comments","events_url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/3980/events","html_url":"https://github.com/gatsbyjs/gatsby/issues/3980","id":296215140,"number":3980,"title":"Error during service worker registration ","user":{"login":"milad1367","id":15375991,"avatar_url":"https://avatars0.githubusercontent.com/u/15375991?v=4","gravatar_id":"","url":"https://api.github.com/users/milad1367","html_url":"https://github.com/milad1367","followers_url":"https://api.github.com/users/milad1367/followers","following_url":"https://api.github.com/users/milad1367/following{/other_user}","gists_url":"https://api.github.com/users/milad1367/gists{/gist_id}","starred_url":"https://api.github.com/users/milad1367/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/milad1367/subscriptions","organizations_url":"https://api.github.com/users/milad1367/orgs","repos_url":"https://api.github.com/users/milad1367/repos","events_url":"https://api.github.com/users/milad1367/events{/privacy}","received_events_url":"https://api.github.com/users/milad1367/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-02-11T18:58:23Z","updated_at":"2018-02-12T14:14:26Z","closed_at":null,"author_association":"NONE","body":"<!-- \r\n  If you're reading this... it means that you want to contribute to the project! Awesome and thanks!\r\n  \r\n  To make it easier for us to help you — please follow the suggested format below (as it makes sense).\r\n  \r\n  Useful Links:\r\n  - Documentation: https://www.gatsbyjs.org/docs/\r\n  - How to Contribute: https://www.gatsbyjs.org/docs/how-to-contribute/\r\n  - How to File an Issue: https://www.gatsbyjs.org/docs/how-to-file-an-issue/\r\n  - Become a Sponsor: https://opencollective.com/gatsby#sponsor\r\n  \r\n  Before opening a new issue, please search existing issues (https://github.com/gatsbyjs/gatsby/issues)\r\n  to double-check your issue isn't already known.\r\n-->\r\n\r\n## Description\r\n\r\ni use --prefix-paths and i defined pathPrefix.\r\nin localhost every things is perfect. but in real host i am encounter with this error : \r\n\r\n```\r\nError during service worker registration: \r\nDOMException {  }\r\nregister-service-worker.js:42:6\r\n\r\n```\r\n### Environment\r\n\r\nGatsby version: \"gatsby\": \"^1.9.153\",\r\nNode.js version: 8.9.2\r\nOperating System: mac os saria\r\n\r\n### File contents (if changed):\r\n\r\n`gatsby-config.js`: \r\n```\r\n   require('dotenv/config');\r\nmodule.exports = {\r\n  siteMetadata: {\r\n    title: 'BullOfTheWeek',\r\n    author: 'Kyle Mathews',\r\n    description: 'BullOfTheWeek.com Crypto Trading Website',\r\n    siteUrl: 'https://gatsbyjs.github.io/gatsby-starter-blog/',\r\n  },\r\n // pathPrefix: '/' + process.env.remoteDevRoot,\r\n  plugins: [\r\n    {\r\n      resolve: `gatsby-source-filesystem`,\r\n      options: {\r\n        path: `${__dirname}/src/pages`,\r\n        name: 'pages',\r\n      },\r\n    },\r\n    {\r\n      resolve: `gatsby-transformer-remark`,\r\n      options: {\r\n        plugins: [\r\n          {\r\n            resolve: `gatsby-remark-images`,\r\n            options: {\r\n              maxWidth: 590,\r\n            },\r\n          },\r\n          {\r\n            resolve: `gatsby-remark-responsive-iframe`,\r\n            options: {\r\n              wrapperStyle: `margin-bottom: 1.0725rem`,\r\n            },\r\n          },\r\n          'gatsby-remark-prismjs',\r\n          'gatsby-remark-copy-linked-files',\r\n          'gatsby-remark-smartypants',\r\n        ],\r\n      },\r\n    },\r\n    `gatsby-transformer-sharp`,\r\n    `gatsby-plugin-sharp`,\r\n    {\r\n      resolve: `gatsby-plugin-google-analytics`,\r\n      options: {\r\n        //trackingId: `ADD YOUR TRACKING ID HERE`,\r\n      },\r\n    },\r\n    `gatsby-plugin-feed`,\r\n    `gatsby-plugin-offline`,\r\n    `gatsby-plugin-react-helmet`,\r\n    {\r\n      resolve: 'gatsby-plugin-typography',\r\n      options: {\r\n        pathToConfigModule: 'src/utils/typography',\r\n      },\r\n    },\r\n  ],\r\n}\r\n\r\n         \r\n\r\n``` \r\n    \r\n\r\n### Steps to reproduce\r\n\r\n1\\. for a test I delete path prefix \r\n\r\n2\\.and build it with: gatsby build \r\n3\\. in localhost everything is ok!\r\n\r\n4\\. but now I have same problems i real host:\r\n\r\n`register-service-worker.js:42 Error during service worker registration: DOMException: Only secure origins are allowed (see: https://goo.gl/Y0ZkNV).\r\n`\r\n\r\nIt does not seem to be a problem with path prefix!\r\n\r\n\r\n\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/comments/364934113","html_url":"https://github.com/gatsbyjs/gatsby/issues/3980#issuecomment-364934113","issue_url":"https://api.github.com/repos/gatsbyjs/gatsby/issues/3980","id":364934113,"user":{"login":"milad1367","id":15375991,"avatar_url":"https://avatars0.githubusercontent.com/u/15375991?v=4","gravatar_id":"","url":"https://api.github.com/users/milad1367","html_url":"https://github.com/milad1367","followers_url":"https://api.github.com/users/milad1367/followers","following_url":"https://api.github.com/users/milad1367/following{/other_user}","gists_url":"https://api.github.com/users/milad1367/gists{/gist_id}","starred_url":"https://api.github.com/users/milad1367/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/milad1367/subscriptions","organizations_url":"https://api.github.com/users/milad1367/orgs","repos_url":"https://api.github.com/users/milad1367/repos","events_url":"https://api.github.com/users/milad1367/events{/privacy}","received_events_url":"https://api.github.com/users/milad1367/received_events","type":"User","site_admin":false},"created_at":"2018-02-12T14:14:26Z","updated_at":"2018-02-12T14:14:26Z","author_association":"NONE","body":"@m-allanson  guy, I deleted gatsby-plugin-offline and that problem solved. \r\nthanks a lot. 👍 \r\nI use prefix-paths and the problem was not with it."}}
{"actor":{"display_login":"milad1367"}}