bflad / chef-stash

Chef Cookbook for Atlassian Stash
Other
37 stars 42 forks source link

kitchen verify fails #160

Closed ghost closed 6 years ago

ghost commented 8 years ago

When I run kitchen verify I get this error

       * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
       SSL validation of HTTPS requests is disabled. HTTPS connections are still
       encrypted, but chef is not able to detect forged replies or man in the middle
       attacks.

       To fix this issue add an entry like this to your configuration file:

         # Verify all HTTPS connections (recommended)
         ssl_verify_mode :verify_peer

         # OR, Verify only connections to chef-server
         verify_api_cert true

       To check your SSL configuration, or troubleshoot errors, you can use the
       `knife ssl check` command like so:

         knife ssl check -c /tmp/kitchen/solo.rb

       * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

       Starting Chef Client, version 11.16.2
       Compiling Cookbooks...

       ================================================================================
       Recipe Compile Error in /tmp/kitchen/cookbooks/compat_resource/libraries/autoload.rb
       ================================================================================

       RuntimeError
       ------------
       This resource is written with Chef 12.5 custom resources, and requires at least Chef 12.0 used with the compat_resource cookbook, it will not work with Chef 11.x clients, and those users must pin their cookbooks to older versions or upgrade.

       Cookbook Trace:
       ---------------
         /tmp/kitchen/cookbooks/compat_resource/libraries/autoload.rb:2:in `<top (required)>'

       Relevant File Content:
       ----------------------
       /tmp/kitchen/cookbooks/compat_resource/libraries/autoload.rb:

         1:  unless Gem::Requirement.new(">= 12.0").satisfied_by?(Gem::Version.new(Chef::VERSION))
         2>>   raise "This resource is written with Chef 12.5 custom resources, and requires at least Chef 12.0 used with the compat_resource cookbook, it will not work with Chef 11.x clients, and those users must pin their cookbooks to older versions or upgrade."
         3:  end
         4:
         5:  # If the gem is already activated rather than the cookbook, then we fail if our version is DIFFERENT.
         6:  # The user said they wanted this cookbook version, they need to have this cookbook version.
         7:  # NOTE: if the gem is installed but on a different version, we simply don't care: the cookbook version wins.
         8:  #       If another gem depends on a different version being there, rubygems will correctly throw the error.
         9:  if Gem.loaded_specs["compat_resource"]
        10:    # Read our current version
        11:    version_rb = IO.read(File.expand_path("../../files/lib/compat_resource/version.rb", __FILE__))

       Running handlers:
       [2016-06-08T20:41:47+00:00] ERROR: Running exception handlers
       Running handlers complete
       [2016-06-08T20:41:47+00:00] ERROR: Exception handlers complete
       [2016-06-08T20:41:47+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
       Chef Client failed. 0 resources updated in 1.975729663 seconds
       [2016-06-08T20:41:47+00:00] ERROR: This resource is written with Chef 12.5 custom resources, and requires at least Chef 12.0 used with the compat_resource cookbook, it will not work with Chef 11.x clients, and those users must pin their cookbooks to older versions or upgrade.
       [2016-06-08T20:41:48+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
             Converge failed on instance <mysql-centos-67>.
             Please see .kitchen/logs/mysql-centos-67.log for more details
              ------Exception-------
             Class: Kitchen::ActionFailed
             Message: SSH exited (1) for command: [sh -c ' sudo -E /opt/chef/bin/chef-solo --config /tmp/kitchen/solo.rb --log_level auto --force-formatter --no-color --json-attributes /tmp/kitchen/dna.json ']
            ----------------------
linc01n commented 8 years ago

This is related to #141

katbyte commented 6 years ago

This has probably been fixed and can be closed as the chef omnibus version is now 12.19 on master @linc01n @peterbaumgarten.

linc01n commented 6 years ago

Thanks @katbyte closing this

ghost commented 6 years ago

Thanks everyone. I completely forgot about this.