summaryrefslogtreecommitdiff
path: root/app/services/clusters/applications/base_helm_service.rb
blob: 9a4ce31cb3943caf233d67b1e8d81d78d07a9d69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
module Clusters
  module Applications
    class BaseHelmService
      attr_accessor :app

      def initialize(app)
        @app = app
      end

      protected

      def cluster
        app.cluster
      end

      def kubeclient
        cluster.kubeclient
      end

      def helm_api
        @helm_api ||= Gitlab::Kubernetes::Helm.new(kubeclient)
      end

      def install_command
        @install_command ||= app.install_command
      end
    end
  end
end