Uploaded image for project: 'Puppet Task Runner'
  1. Puppet Task Runner
  2. BOLT-583

Unable to use "localhost" as a node on Windows

    Details

    • Template:
    • Acceptance Criteria:
      Hide

      Either this should be implemented for Windows

      or

      The local detection should be disabled on Windows so I can use "localhost" and not get a wall of error text.

      Show
      Either this should be implemented for Windows or The local detection should be disabled on Windows so I can use "localhost" and not get a wall of error text.
    • Sprint:
      Bolt Kanban
    • Method Found:
      Needs Assessment
    • Release Notes:
      Bug Fix
    • Release Notes Summary:
      Do not default to local transport when targeting localhost on windows.
    • QA Risk Assessment:
      Needs Assessment

      Description

      When running a PowerShell task on a local computer with a correctly configured WinRM service, but with the target node of 'localhost' I get a message saying it's not supported and really obtuse error stack.

      Using a simple trick of --nodes '127.0.0.1' works around the issue.

      Note - The IP6 loopback ::1 does not work

      example

      C:\Source\puppetlabs-wsus_client [(f2ade67...) +1 ~0 -0 !]> bolt task run wsus_client::update_history --modulepath .\spec\fixtures\modules\ --nodes localhost --transport winrm --no-ssl --user ******** --password
      Please enter your password:
      C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/transport/local.rb:24:in `initialize': The local transport is not yet implemented on Windows (NotImplementedError)
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:25:in `new'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:25:in `block (2 levels) in initialize'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/delay.rb:87:in `block in value'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/mri_lockable_object.rb:38:in `block in synchronize'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/mri_lockable_object.rb:38:in `synchronize'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/mri_lockable_object.rb:38:in `synchronize'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/delay.rb:83:in `value'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/delay.rb:135:in `wait'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/obligation.rb:87:in `wait!'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:39:in `transport'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:52:in `block in batch_execute'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:51:in `each'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:51:in `flat_map'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:51:in `batch_execute'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:161:in `block in run_task'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:101:in `log_action'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/lib/bolt/executor.rb:157:in `run_task'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/bolt-modules/boltlib/lib/puppet/functions/run_task.rb:112:in `run_task_raw'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/vendored/puppet/lib/puppet/pops/functions/dispatch.rb:60:in `invoke'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/vendored/puppet/lib/puppet/pops/functions/dispatcher.rb:43:in `block in dispatch'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/vendored/puppet/lib/puppet/pops/functions/dispatcher.rb:42:in `catch'
              from C:/Program Files/Puppet Labs/Bolt/lib/ruby/gems/2.4.0/gems/bolt-0.20.5/vendored/puppet/lib/puppet/pops/functions/dispatcher.rb:42:in `dispatch'
      ...
      

       

      The local detection should be disabled on Windows so I can use "localhost" and not get a wall of error text.
      Documentation should clarify how and where the local transport works.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                cas.donoghue Cas Donoghue
                Reporter:
                glenn.sarti Glenn Sarti
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Zendesk Support