diff --git a/Gemfile b/Gemfile
index 3fab51a0d44cf2799f5f32d9e5eeca0f6f613f5d..0b8050ccc39a3c75bc79361382561e9c9a81eece 100644
--- a/Gemfile
+++ b/Gemfile
@@ -327,7 +327,9 @@ gem 'loofah', '~> 2.22.0' # rubocop:todo Gemfile/MissingFeatureCategory
 gem 'licensee', '~> 9.16' # rubocop:todo Gemfile/MissingFeatureCategory
 
 # Detect and convert string character encoding
-gem 'charlock_holmes', '~> 0.7.7' # rubocop:todo Gemfile/MissingFeatureCategory
+# We forked charlock_holmes at https://gitlab.com/gitlab-org/ruby/gems/charlock_holmes
+# but changed it's name to 'static_holmes' in the gemspec file.
+gem 'static_holmes', '~> 0.7.7', require: 'charlock_holmes' # rubocop:todo Gemfile/MissingFeatureCategory
 
 # Detect mime content type from content
 gem 'ruby-magic', '~> 0.6' # rubocop:todo Gemfile/MissingFeatureCategory
diff --git a/Gemfile.checksum b/Gemfile.checksum
index 0fec7e38bb5269bfb4ad80ae305ef2496a93d668..5a61d1e78e5580fba0a573f11179ff68cb3af3d3 100644
--- a/Gemfile.checksum
+++ b/Gemfile.checksum
@@ -73,7 +73,6 @@
 {"name":"cbor","version":"0.5.9.8","platform":"ruby","checksum":"9ee097fc58d9bc5e406d112cd2d4e112c7354ec16f8b6ff34e4732c1e44b4eb7"},
 {"name":"character_set","version":"1.8.0","platform":"java","checksum":"2d94ac33d6569434cf1ba464012b5e98010f5dafbd7b750e8d7db79f4c8eb8f7"},
 {"name":"character_set","version":"1.8.0","platform":"ruby","checksum":"2b7317462adaedff0bd1576ae86d71bc5efe133a5d0b7c257021b00fe3153f51"},
-{"name":"charlock_holmes","version":"0.7.7","platform":"ruby","checksum":"1790eca3f661ffa6bbf5866c53c7191e4b8472626fc4997ff9dbe7c425e2cb43"},
 {"name":"chef-config","version":"18.3.0","platform":"ruby","checksum":"c183a2ff41da8d63b1e4a60853c9c701a053ab9afe13df767a578db5f07072df"},
 {"name":"chef-utils","version":"18.3.0","platform":"ruby","checksum":"827f7aace26ba9f5f8aca45059644205cc715baded80229f1fd5518d21970701"},
 {"name":"chunky_png","version":"1.4.0","platform":"ruby","checksum":"89d5b31b55c0cf4da3cf89a2b4ebc3178d8abe8cbaf116a1dba95668502fdcfe"},
@@ -628,6 +627,7 @@
 {"name":"state_machines","version":"0.5.0","platform":"ruby","checksum":"23e6249d374a920b528dccade403518b4abbd83841a3e2c9ef13e6f1a009b102"},
 {"name":"state_machines-activemodel","version":"0.8.0","platform":"ruby","checksum":"e932dab190d4be044fb5f9cab01a3ea0b092c5f113d4676c6c0a0d49bf738d2c"},
 {"name":"state_machines-activerecord","version":"0.8.0","platform":"ruby","checksum":"072fb701b8ab03de0608297f6c55dc34ed096e556fa8f77e556f3c461c71aab6"},
+{"name":"static_holmes","version":"0.7.7","platform":"ruby","checksum":"87c426d821728915518444342aaac58d078b359e0f4a34e4e0516b0daadc8207"},
 {"name":"strings","version":"0.2.1","platform":"ruby","checksum":"933293b3c95cf85b81eb44b3cf673e3087661ba739bbadfeadf442083158d6fb"},
 {"name":"strings-ansi","version":"0.2.0","platform":"ruby","checksum":"90262d760ea4a94cc2ae8d58205277a343409c288cbe7c29416b1826bd511c88"},
 {"name":"swd","version":"1.3.0","platform":"ruby","checksum":"bc382a19e1d36a95529b25152976db61b80376c3d486b21c8dd60ac2b5c06389"},
diff --git a/Gemfile.lock b/Gemfile.lock
index 6d0c12c959aea9485257ada0947d3a80bb2618a6..93b27adcc568a902b56fef9dcab0788e306f56c1 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -392,7 +392,6 @@ GEM
       ssrf_filter (~> 1.0, < 1.1.0)
     cbor (0.5.9.8)
     character_set (1.8.0)
-    charlock_holmes (0.7.7)
     chef-config (18.3.0)
       addressable
       chef-utils (= 18.3.0)
@@ -1644,6 +1643,7 @@ GEM
     state_machines-activerecord (0.8.0)
       activerecord (>= 5.1)
       state_machines-activemodel (>= 0.8.0)
+    static_holmes (0.7.7)
     strings (0.2.1)
       strings-ansi (~> 0.2)
       unicode-display_width (>= 1.5, < 3.0)
@@ -1851,7 +1851,6 @@ DEPENDENCIES
   capybara (~> 3.40)
   capybara-screenshot (~> 1.0.26)
   carrierwave (~> 1.3)
-  charlock_holmes (~> 0.7.7)
   circuitbox (= 2.0.0)
   click_house-client!
   cloud_profiler_agent (~> 0.0.0)!
@@ -2120,6 +2119,7 @@ DEPENDENCIES
   ssh_data (~> 1.3)
   stackprof (~> 0.2.25)
   state_machines-activerecord (~> 0.8.0)
+  static_holmes (~> 0.7.7)
   sys-filesystem (~> 1.4.3)
   tanuki_emoji (~> 0.9)
   telesignenterprise (~> 2.2)