Module: Berkshelf::Config::BerksConfig

Defined in:
lib/berkshelf/config.rb

Class Method Summary collapse

Class Method Details

.extended(base) ⇒ Object



105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
# File 'lib/berkshelf/config.rb', line 105

def self.extended(base)
  base.class_exec do
    config_strict_mode true
    config_context :api do
      default :timeout, "30"
    end
    config_context :chef do
      default :chef_server_url, Berkshelf.chef_config.chef_server_url
      default :validation_client_name, Berkshelf.chef_config.validation_client_name
      default :validation_key_path, Berkshelf.chef_config.validation_key
      default :client_key, Berkshelf.chef_config.client_key
      default :node_name, Berkshelf.chef_config.node_name
      default :trusted_certs_dir, Berkshelf.chef_config.trusted_certs_dir
      default :artifactory_api_key, Berkshelf.chef_config.artifactory_api_key
    end
    config_context :cookbook do
      default :copyright, nil
      default :email, nil
      default :license, nil
    end
    default :allowed_licenses, []
    default :raise_license_exception, false
    config_context :vagrant do
      config_context :vm do
        default :box, nil
        default :forward_port, nil
        default :provision, nil
        config_context :omnibus do
          default :version, nil
        end
      end
    end
    config_context :ssl do
      default :verify, true
      default :cert_store, false
      default :ca_file, nil
      default :ca_path, nil
      default :ca_cert, nil
      default :client_cert, nil
      default :client_key, nil
    end
    default :github, []
    default :gitlab, []
    # :git, :ssh, or :https
    default :github_protocol, :https
  end
end