Sha256: a7508ef375e26e77f4fd31c97ba189d8be949da64170d345387824769d7e1974

Contents?: true

Size: 1.26 KB

Versions: 2

Compression:

Stored size: 1.26 KB

Contents

require 'rake_factory'
require 'docker'

require_relative '../tasks'

module RakeDocker
  module TaskSets
    class All < RakeFactory::TaskSet
      prepend RakeFactory::Namespaceable

      parameter :image_name, required: true
      parameter :repository_name, required: true
      parameter :repository_url, required: true

      parameter :work_directory, required: true

      parameter :copy_spec, default: []
      parameter :create_spec, default: []

      parameter :argument_names, default: []

      parameter :tags, required: true

      parameter :credentials

      parameter :build_args

      parameter :clean_task_name, default: :clean
      parameter :prepare_task_name, default: :prepare
      parameter :build_task_name, default: :build
      parameter :tag_task_name, default: :tag
      parameter :push_task_name, default: :push
      parameter :publish_task_name, default: :publish

      task Tasks::Clean, name: ->(ts) { ts.clean_task_name }
      task Tasks::Prepare, name: ->(ts) { ts.prepare_task_name }
      task Tasks::Build, name: ->(ts) { ts.build_task_name }
      task Tasks::Tag, name: ->(ts) { ts.tag_task_name }
      task Tasks::Push, name: ->(ts) { ts.push_task_name }
      task Tasks::Publish, name: ->(ts) { ts.publish_task_name }
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rake_docker-1.3.0 lib/rake_docker/task_sets/all.rb
rake_docker-1.2.0.pre.1 lib/rake_docker/task_sets/all.rb