html - GitLab 默认 url 不安全

标签 html git ssl gitlab

我正在尝试设置一个 Gitlab 页面,以使用标准 userName.gitlab.io 域来托管我的个人网站(简历、代码示例之类的东西)。
目前,它只是 index.htmlreadme.md 中的一个 HelloWorld 我按下去检查它是否正常工作(确实如此)。

问题是当我在 Firefox 上通过 https 访问网站时,我得到:

This site uses HTTP Strict Transport Security (HSTS).

高级消息

mr.brompton.gitlab.io uses an invalid security certificate. The certificate is only valid for the following names: *.gitlab.io, gitlab.io Error code: SSL_ERROR_BAD_CERT_DOMAIN

我可以通过 Chrome 访问,但只能使用 http。我阅读的所有文档都建议 https 应该自动运行。我又一次觉得我错过了一些愚蠢的东西。也许我应该只添加自己的证书?

可以在@ mr.brompton.gitlab.iogitlab.com/mr.brompton 上找到 repo

我的配置文件:

  # Full project: https://gitlab.com/pages/plain-html
pages:
  stage: deploy
  script:
  - mkdir .public
  - cp -r * .public
  - mv .public public
artifacts:
  paths:
  - public
only:
  - master

最佳答案

如我所料,答案很简单。该项目名为 mr.brompton,这意味着我的域是 mr.brompton.gitlab.io。该证书对 *.gitlab.io 有效。这意味着在 mr.* 之后尝试查找 gitlab.io 后证书返回无效。我通过将我的用户名、项目路径和项目名称更改为 mr-brompton 解决了这个问题。我还将更改本地计算机上的 url、用户名和所有其他关联。

关于html - GitLab 默认 url 不安全,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45970339/

相关文章:

html - 为什么 HTML 没有用于关闭带有内容的标记的速记方法,这有充分的理由吗?

html - 如何在按钮出现/消失时保持 Bootstrap 行高相同

git - 从 Private Repo 下载 Git 存档 tarball 时遇到问题

java.security.InvalidKeyException : PBES2 AlgorithmParameters not available

android - 解析 CSV 行后出现 SSLProtocolException

html - 你能有背景图片 : linear-gradient( to center. ..);

javascript - jQuery,删除添加到toggleClass元素的填充

git - 修改对共享仓库的 Git 提交

git - 所有分支都是平等的吗?

git - 由于 ECMDERR "Server aborted the SSL handshake",Bower 无法下载