Sha256: 3b71175f8df18498ee2a37b459f504f79d4c8f8d7987516c93689d87fd67d77a

Contents?: true

Size: 385 Bytes

Versions: 16

Compression:

Stored size: 385 Bytes

Contents

module Specinfra::Backend
  class Dockerfile < Specinfra::Backend::Base
    def initialize
      @lines = []
      ObjectSpace.define_finalizer(self) {
        File.write("Dockerfile", @lines.join("\n"))
      }
    end

    def run_command(cmd, opts={})
      @lines << "RUN #{cmd}"
      CommandResult.new
    end

    def from(base)
      @lines << "FROM #{base}"
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
specinfra-2.0.0.beta47 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta46 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta45 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta44 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta43 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta42 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta41 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta40 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta39 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta38 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta37 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta36 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta35 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta34 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta33 lib/specinfra/backend/dockerfile.rb
specinfra-2.0.0.beta32 lib/specinfra/backend/dockerfile.rb