diff options
author | Dylan Griffith <dyl.griffith@gmail.com> | 2018-07-27 15:06:17 +0300 |
---|---|---|
committer | Dylan Griffith <dyl.griffith@gmail.com> | 2018-07-30 16:08:32 +0300 |
commit | b169ec7fd3f1b643a1e68d4c9e16247251bf5fe5 (patch) | |
tree | aec1885fc7f37b370371f430da0841c451d971a0 /lib | |
parent | c7360d13be8266ba82f68f2c727ad2cb1b1b631c (diff) |
Expand ca -> certificate_authority in Helm::Certificate
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/kubernetes/helm/certificate.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/gitlab/kubernetes/helm/certificate.rb b/lib/gitlab/kubernetes/helm/certificate.rb index cebf3f1461a..c344add82cd 100644 --- a/lib/gitlab/kubernetes/helm/certificate.rb +++ b/lib/gitlab/kubernetes/helm/certificate.rb @@ -22,16 +22,16 @@ module Gitlab end def self.generate_root - _issue(signed_by: nil, expires_in: INFINITE_EXPIRY, ca: true) + _issue(signed_by: nil, expires_in: INFINITE_EXPIRY, certificate_authority: true) end def issue(expires_in: SHORT_EXPIRY) - self.class._issue(signed_by: self, expires_in: expires_in, ca: false) + self.class._issue(signed_by: self, expires_in: expires_in, certificate_authority: false) end private - def self._issue(signed_by:, expires_in:, ca:) + def self._issue(signed_by:, expires_in:, certificate_authority:) key = OpenSSL::PKey::RSA.new(4096) public_key = key.public_key @@ -48,7 +48,7 @@ module Gitlab cert.serial = 0x0 cert.version = 2 - if ca + if certificate_authority extension_factory = OpenSSL::X509::ExtensionFactory.new extension_factory.subject_certificate = cert extension_factory.issuer_certificate = cert |