Sha256: b2710360f1baccf4608e36fe6a0b8c466ba68fd317faabf4b987fa7ef60b2acd

Contents?: true

Size: 520 Bytes

Versions: 49

Compression:

Stored size: 520 Bytes

Contents

module Vidar
  class Run
    class << self
      def docker(command)
        system("docker #{command}") || exit(1)
      end

      def docker_compose(command)
        args = %w[revision current_branch].map { |arg| "#{arg.upcase}=#{Config.get!(arg.to_sym)}" }
        system("#{args.join(' ')} docker-compose -f #{Config.get!(:compose_file)} #{command}") || exit(1)
      end

      def kubectl(command)
        system("kubectl --namespace=#{Config.get!(:namespace)} #{command}") || exit(1)
      end
    end
  end
end

Version data entries

49 entries across 49 versions & 1 rubygems

Version Path
vidar-1.7.0 lib/vidar/run.rb
vidar-1.6.0 lib/vidar/run.rb
vidar-1.5.4 lib/vidar/run.rb
vidar-1.5.3 lib/vidar/run.rb
vidar-1.5.2 lib/vidar/run.rb
vidar-1.5.1 lib/vidar/run.rb
vidar-1.5.0 lib/vidar/run.rb
vidar-1.4.3 lib/vidar/run.rb
vidar-1.4.2 lib/vidar/run.rb
vidar-1.4.1 lib/vidar/run.rb
vidar-1.4.0 lib/vidar/run.rb
vidar-1.3.2 lib/vidar/run.rb
vidar-1.3.1 lib/vidar/run.rb
vidar-1.3.0 lib/vidar/run.rb
vidar-1.2.0 lib/vidar/run.rb
vidar-1.1.5 lib/vidar/run.rb
vidar-1.1.4 lib/vidar/run.rb
vidar-1.1.3 lib/vidar/run.rb
vidar-1.1.2 lib/vidar/run.rb
vidar-1.1.1 lib/vidar/run.rb