Class: Gitlab::Kubernetes::ServiceAccountToken
- Inherits:
-
Object
- Object
- Gitlab::Kubernetes::ServiceAccountToken
- Defined in:
- lib/gitlab/kubernetes/service_account_token.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#namespace_name ⇒ Object
readonly
Returns the value of attribute namespace_name.
-
#service_account_name ⇒ Object
readonly
Returns the value of attribute service_account_name.
Instance Method Summary collapse
- #generate ⇒ Object
-
#initialize(name, service_account_name, namespace_name) ⇒ ServiceAccountToken
constructor
A new instance of ServiceAccountToken.
Constructor Details
#initialize(name, service_account_name, namespace_name) ⇒ ServiceAccountToken
Returns a new instance of ServiceAccountToken.
8 9 10 11 12 |
# File 'lib/gitlab/kubernetes/service_account_token.rb', line 8 def initialize(name, service_account_name, namespace_name) @name = name @service_account_name = service_account_name @namespace_name = namespace_name end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
6 7 8 |
# File 'lib/gitlab/kubernetes/service_account_token.rb', line 6 def name @name end |
#namespace_name ⇒ Object (readonly)
Returns the value of attribute namespace_name.
6 7 8 |
# File 'lib/gitlab/kubernetes/service_account_token.rb', line 6 def namespace_name @namespace_name end |
#service_account_name ⇒ Object (readonly)
Returns the value of attribute service_account_name.
6 7 8 |
# File 'lib/gitlab/kubernetes/service_account_token.rb', line 6 def service_account_name @service_account_name end |
Instance Method Details
#generate ⇒ Object
14 15 16 |
# File 'lib/gitlab/kubernetes/service_account_token.rb', line 14 def generate ::Kubeclient::Resource.new(metadata: , type: service_acount_token_type) end |