diff --git a/rails/rubocop-for-gem.yml b/rails/rubocop-for-gem.yml
index 7890b9d40d9dafe0bd118ac1481ec1b83a3910e4..6ce1142e50106ccd469bfdc6c6fc605c759712d6 100644
--- a/rails/rubocop-for-gem.yml
+++ b/rails/rubocop-for-gem.yml
@@ -51,7 +51,7 @@ Metrics/AbcSize:
 Metrics/BlockLength:
   AllowedMethods: ['class_eval', 'module_eval', 'refine'] # default: 'refine'
   CountAsOne: &array_hash_heredoc_method_call ['array', 'hash', 'heredoc', 'method_call'] # default: []
-  Exclude: &test_config_db ['test/**/*', 'config/**/*', 'db/**/*']
+  Exclude: &test_config_db ['*.gemspec', '*/config/**/*', 'test/**/*', 'config/**/*', 'db/**/*']
 
 # default is too restrictive, having some restriction incentivizes to split up overly large classes
 Metrics/ClassLength: