gitlab更新后打开gitlab-runner面板报错

更新迁移gitlab-ce后出现以下错误

OpenSSL::Cipher::CipherError ():
  
lib/gitlab/crypto_helper.rb:27:in `aes256_gcm_decrypt'
app/models/concerns/token_authenticatable_strategies/encrypted.rb:55:in `get_token'
app/models/concerns/token_authenticatable_strategies/base.rb:27:in `ensure_token'
app/models/concerns/token_authenticatable_strategies/encrypted.rb:42:in `ensure_token'

# 解决方案

gitlab-rails c
irb(main):001:0> settings = ApplicationSetting.last
......
irb(main):002:0> settings.update_column(:runners_registration_token_encrypted, nil)
irb(main):003:0> settings.update_column(:encrypted_ci_jwt_signing_key, nil)
irb(main):005:0> exit
gitlab-ctl restart

如果上述方案没有解决,可以尝试删除数据库中之前有问题的runner数据

# 以下语句会删除所有已注册的runner,删除后需要重新注册
delete from ci_runners where contacted_at < date(NOW());

# 参考