chef 15.0.298-universal-mingw32 → 15.0.300-universal-mingw32

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c10389685690b3412374156b687dd8a87ff02bb495f32570a0fa33ef25dc9bdf
4
- data.tar.gz: 729b33c025af44c37f7f9f6091c8a5ca03904b45a654307c89590d9d7a75fc03
3
+ metadata.gz: 5ac1355fd1d581480c9d391d2d42d7540de2cf59d6fe333c05c3c5c69f04989d
4
+ data.tar.gz: 386c6ced23a3d12ab56632dc78058bd48b92e673beb107fd84f45489d4fdcf5d
5
5
  SHA512:
6
- metadata.gz: c2f72876a8a9d4e554eca0aa39722d06bf64906530a9c662129a1c6ec8877ec1bab3c1af68e4c898da854eb07194198eb3cf88846599008759ba3af99da80ee9
7
- data.tar.gz: 93eefee2050f499f0c9c51744a95e40014f7c271171508905ca7441548995f147254f88e542607637a20a1dee71a8ac3df711bdf01f1e99e69bf3977bf5cec50
6
+ metadata.gz: 4ff6557d77f8f6eaffa1da837b4ca8d40f6437da864486f1f242f34d19ee410b8e51d76c9a2e71bcf24c05a21eb18b72684529bad7e671d2da4e9e0d07d8fc04
7
+ data.tar.gz: 98879492b6a65dc1d8d766c5f2ee04f55618a6a1ea6aca6b0e7f4dae16135fc3f26483e29e585e1e94b013e331a22d2ccdb96994b7f16e5d3378e08417709b5f
@@ -27,8 +27,10 @@ require "tempfile"
27
27
  require_relative "../providers"
28
28
  require_relative "../resources"
29
29
  require_relative "../dist"
30
+ require "license_acceptance/cli_flags/mixlib_cli"
30
31
 
31
32
  class Chef::Application::Apply < Chef::Application
33
+ include LicenseAcceptance::CLIFlags::MixlibCLI
32
34
 
33
35
  banner "Usage: chef-apply [RECIPE_FILE | -e RECIPE_TEXT | -s] [OPTIONS]"
34
36
 
@@ -30,10 +30,12 @@ require "pathname"
30
30
  require "chef-config/mixin/dot_d"
31
31
  require "mixlib/archive"
32
32
  require_relative "../dist"
33
+ require "license_acceptance/cli_flags/mixlib_cli"
33
34
 
34
35
  class Chef::Application::Solo < Chef::Application
35
36
  include Chef::Mixin::ShellOut
36
37
  include ChefConfig::Mixin::DotD
38
+ include LicenseAcceptance::CLIFlags::MixlibCLI
37
39
 
38
40
  option :config_file,
39
41
  short: "-c CONFIG",
@@ -865,6 +865,7 @@ class Chef
865
865
  def ssh_opts
866
866
  opts = {}
867
867
  return opts if winrm?
868
+ opts[:pty] = true # ensure we can talk to systems with requiretty set true in sshd config
868
869
  opts[:non_interactive] = true # Prevent password prompts from underlying net/ssh
869
870
  opts[:forward_agent] = (config_value(:ssh_forward_agent) === true)
870
871
  opts[:connection_timeout] = session_timeout
@@ -23,7 +23,7 @@ require_relative "version_string"
23
23
 
24
24
  class Chef
25
25
  CHEF_ROOT = File.expand_path("../..", __FILE__)
26
- VERSION = Chef::VersionString.new("15.0.298")
26
+ VERSION = Chef::VersionString.new("15.0.300")
27
27
  end
28
28
 
29
29
  #
@@ -1015,6 +1015,7 @@ describe Chef::Knife::Bootstrap do
1015
1015
  verify_host_key: false,
1016
1016
  port: 9999,
1017
1017
  non_interactive: true,
1018
+ pty: true,
1018
1019
  }
1019
1020
  end
1020
1021
 
@@ -1069,6 +1070,7 @@ describe Chef::Knife::Bootstrap do
1069
1070
  verify_host_key: false, # Config
1070
1071
  port: 12, # cli
1071
1072
  non_interactive: true,
1073
+ pty: true,
1072
1074
  }
1073
1075
  end
1074
1076
 
@@ -1120,6 +1122,7 @@ describe Chef::Knife::Bootstrap do
1120
1122
  sudo_password: "blah",
1121
1123
  verify_host_key: true,
1122
1124
  non_interactive: true,
1125
+ pty: true,
1123
1126
  }
1124
1127
  end
1125
1128
  it "generates a config hash using the CLI options and pulling nothing from Chef::Config" do
@@ -1143,6 +1146,7 @@ describe Chef::Knife::Bootstrap do
1143
1146
  sudo: false,
1144
1147
  verify_host_key: "always",
1145
1148
  non_interactive: true,
1149
+ pty: true,
1146
1150
  connection_timeout: 60,
1147
1151
  }
1148
1152
  end
@@ -1491,33 +1495,38 @@ describe Chef::Knife::Bootstrap do
1491
1495
 
1492
1496
  context "for ssh" do
1493
1497
  let(:connection_protocol) { "ssh" }
1498
+ let(:default_opts) do
1499
+ {
1500
+ non_interactive: true,
1501
+ pty: true,
1502
+ forward_agent: false,
1503
+ connection_timeout: 60,
1504
+ }
1505
+ end
1506
+
1507
+ context "by default" do
1508
+ it "returns a configuration hash with appropriate defaults" do
1509
+ expect(knife.ssh_opts).to eq default_opts
1510
+ end
1511
+ end
1512
+
1494
1513
  context "when ssh_forward_agent has a value" do
1495
1514
  before do
1496
1515
  knife.config[:ssh_forward_agent] = true
1497
1516
  end
1498
- it "returns a configuration hash with forward_agent set to true. non-interactive is always true" do
1499
- expect(knife.ssh_opts).to eq({ forward_agent: true, non_interactive: true, connection_timeout: 60 })
1500
- end
1501
- end
1502
- context "when ssh_forward_agent is not set" do
1503
- it "returns a configuration hash with forward_agent set to false. non-interactive is always true" do
1504
- expect(knife.ssh_opts).to eq({ forward_agent: false, non_interactive: true, connection_timeout: 60 })
1517
+ it "returns a default configuration hash with forward_agent set to true" do
1518
+ expect(knife.ssh_opts).to eq(default_opts.merge(forward_agent: true))
1505
1519
  end
1506
1520
  end
1507
1521
  context "when session_timeout has a value" do
1508
1522
  before do
1509
1523
  knife.config[:session_timeout] = 120
1510
1524
  end
1511
- it "returns a configuration hash with connection_timeout value." do
1512
- expect(knife.ssh_opts).to eq({ forward_agent: false, non_interactive: true, connection_timeout: 120 })
1525
+ it "returns a default configuration hash with updated timeout value." do
1526
+ expect(knife.ssh_opts).to eq(default_opts.merge(connection_timeout: 120))
1513
1527
  end
1514
1528
  end
1515
1529
 
1516
- context "when session_timeout is not set" do
1517
- it "returns a configuration hash with connection_timeout default value." do
1518
- expect(knife.ssh_opts).to eq({ forward_agent: false, non_interactive: true, connection_timeout: 60 })
1519
- end
1520
- end
1521
1530
  end
1522
1531
 
1523
1532
  context "for winrm" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef
3
3
  version: !ruby/object:Gem::Version
4
- version: 15.0.298
4
+ version: 15.0.300
5
5
  platform: universal-mingw32
6
6
  authors:
7
7
  - Adam Jacob
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-15 00:00:00.000000000 Z
11
+ date: 2019-05-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: chef-config
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 15.0.298
19
+ version: 15.0.300
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 15.0.298
26
+ version: 15.0.300
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: train-core
29
29
  requirement: !ruby/object:Gem::Requirement