No description
  • Ruby 97.6%
  • Shell 2%
  • Dockerfile 0.4%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
dependabot[bot] 56b4c33f65
Bump ruby/setup-ruby from 1.316.0 to 1.319.0 (#249)
Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.316.0 to 1.319.0.
- [Release notes](https://github.com/ruby/setup-ruby/releases)
- [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb)
- [Commits](d45b1a4e94...003a5c4d8d)

---
updated-dependencies:
- dependency-name: ruby/setup-ruby
  dependency-version: 1.319.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-07-21 11:20:54 -07:00
.github Bump ruby/setup-ruby from 1.316.0 to 1.319.0 (#249) 2026-07-21 11:20:54 -07:00
config Run script/update-cdn-ips 2022-06-08 14:45:10 -04:00
lib bump up package version 2026-04-15 11:11:05 -07:00
script Apply suggestions from code review 2024-09-16 10:50:59 -07:00
spec Add Domain method for testing possible wildcard records 2025-06-05 14:22:34 -04:00
.dockerignore Actually upgrade to Ruby 2.7 2020-07-28 20:04:48 -04:00
.gitignore Remove accidentally committed vendor/bundle and add to .gitignore 2026-04-15 16:13:07 +00:00
.rspec dont monkey patch rspec 2016-10-29 15:33:30 -04:00
.rubocop.yml Update .rubocop.yml 2024-01-22 16:12:28 -06:00
.ruby-version Update .ruby-version 2025-04-01 15:23:48 -05:00
Dockerfile Simplify Dockerfile commands and update RubyGems 2025-04-01 15:20:03 -05:00
Gemfile retry 2024-09-13 16:43:51 -07:00
github-pages-health-check.gemspec Update addressable dependency from ~> 2.8.7 to ~> 2.9 to fix GHSA-h27x-rffw-24p4 2026-04-15 16:12:27 +00:00
LICENSE.md bump copyright date 2017-10-23 11:59:33 -04:00
README.md Update README.md with link to Actions results 2023-10-19 10:16:45 -05:00

GitHub Pages Health Check

Checks your GitHub Pages site for common DNS configuration issues

Build Status Gem Version

Installation

gem install github-pages-health-check

Usage

Basic Usage

> check = GitHubPages::HealthCheck::Site.new("choosealicense.com")
=> #<GitHubPages::HealthCheck::Site @domain="choosealicense.com" valid?=true>
> check.valid?
=> true

An invalid domain

> check = GitHubPages::HealthCheck::Site.new("foo.github.com")
> check.valid?
=> false
> check.valid!
raises GitHubPages::HealthCheck::Errors::InvalidCNAMEError

Retrieving specific checks

> check.domain.should_be_a_record?
=> true
> check.domain.a_record?
=> true

Getting checks in bulk

> check.to_hash
=> {
 :cloudflare_ip?=>false,
 :old_ip_address?=>false,
 :a_record?=>true,
 :cname_record?=>false,
 :valid_domain?=>true,
 :apex_domain?=>true,
 :should_be_a_record?=>true,
 :pointed_to_github_user_domain?=>false,
 :pointed_to_github_pages_ip?=>false,
 :pages_domain?=>false,
 :valid?=>true
}
> check.to_json
=> "{\"cloudflare_ip?\":false,\"old_ip_address?\":false,\"a_record?\":true,\"cname_record?\":false,\"valid_domain?\":true,\"apex_domain?\":true,\"should_be_a_record?\":true,\"pointed_to_github_user_domain?\":false,\"pointed_to_github_pages_ip?\":false,\"pages_domain?\":false,\"valid?\":true}"

Getting the reason a domain is invalid

> check = GitHubPages::HealthCheck::Site.new "developer.facebook.com"
> check.valid?
=> false
> check.reason
=> #<GitHubPages::HealthCheck::InvalidCNAME>
> check.reason.message
=> "CNAME does not point to GitHub Pages"

Repository checks

Repository checks require a personal access or OAuth token with repo or scope. This can be passed as the second argument to the Site or Repository constructors like so:

check = GitHubPages::HealthCheck::Site.new "github/pages-health-check", access_token: "1234

You can also set OCTOKIT_ACCESS_TOKEN as an environmental variable, or via a .env file in your working directory.

Command Line

./script/check pages.github.com

host: pages.github.com
uri: https://pages.github.com/
nameservers: :default
dns_resolves?: true
proxied?: false
cloudflare_ip?: false
fastly_ip?: false
old_ip_address?: false
a_record?: false
cname_record?: true
mx_records_present?: false
valid_domain?: true
apex_domain?: false
should_be_a_record?: false
cname_to_github_user_domain?: true
cname_to_pages_dot_github_dot_com?: false
cname_to_fastly?: false
pointed_to_github_pages_ip?: false
non_github_pages_ip_present?: false
pages_domain?: true
served_by_pages?: true
valid?: true
reason:
https?: true
enforces_https?: true
https_error:
https_eligible?: true
caa_error:
dns_zone_soa?: false
dns_zone_ns?: false