Closed riponbanik closed 6 years ago
sorry can't tell from this. you need to show the kitchen.yml file run kitchen with -l debug and then look at the logs.
@neillturner Thanks I have uploaded kitchen.yml -
https://gist.github.com/riponbanik/323cd14d549197ec361259b71ce1df7d
The logs that I have put is the debug log.
Update: I have run it from linux machine as well - but the same issue at the end failing to transfer files but i can already see files under /tmp/kitchen directory
-----> Converging
Transferring files to <default-amazon-20180810>
D TIMING: scp async upload (Kitchen::Transport::Ssh) D Cleaning up local sandbox in /tmp/default-amazon-20180810-sandbox-20181005-8675-1d69w7e
When I removed the roles_path it moved to install ansible but now upload failing - I am running Ubuntu Linux from Windows 10
18-10-05T11:10:57.969053 #2014] INFO -- default-amazon-20180810: Transferring files to
My purpose is to test the roles/modules that I create.
@neillturner - I have resolved the issue. It seems the scp upload is just unstable. It sometimes fails. Also I needed to install pywinrm. Do you happen to know how to make it automated e.g. adding another shell provisioner before running ansible-playbook - i do not seem to find any reference regarding this.
look at the custom_pre_play_command and custom_post_install_command parameters where you can add each script to do each stuff -)
To improve perform of uploads see https://rubygems.org/gems/kitchen-sync ormy https://rubygems.org/gems/kitchen-ssh. which support ssh_gzip format
Config
platforms:
name: windows-2012r2
transport: name: winrm username: administrator
driver: image_id: ami-xxx private_ip_address: '10.x.2.218' retryable_tries: 60 retryable_sleep: 10
name: amazon-20180810 driver: image_id: ami-xxx private_ip_address: '10.x.2.217'
transport: username: ec2-user
provisioner: name: ansible_playbook hosts: all roles_path: ../
require_ansible_repo: false
ansible_verbose: true ansible_version: latest
ansible_connection: winrm ansible_inventory: inventory/hosts ansible_host_key_checking: false ansible_verbose: true ansible_verbosity: 4 playbook: playbook.yml require_windows_support: true require_chef_for_busser: false verifier: name: shell command: echo 'Skipping Verify'
Debug Log - D sudo -E rm -rf /tmp/kitchen/modules /tmp/kitchen/roles /tmp/kitchen/group_vars /tmp/kitchen/host_vars; mkdir -p /tmp/kitchen D [SSH] ec2-user@10.x.2.217<{:user_known_hosts_file=>"/dev/null", :port=>22, :compression=>false, :compression_level=>0, :keepalive=>true, :keepalive_interval=>60, :timeout=>10, :keys_only=>true, :keys=>["/c/Workspace/xx/automation/xx/.kitchen/default-amazon-20180810.pem"], :auth_methods=>["publickey"], :verify_host_key=>false}> (sudo -E rm -rf /tmp/kitchen/modules /tmp/kitchen/roles /tmp/kitchen/group_vars /tmp/kitchen/host_vars; mkdir -p /tmp/kitchen) D [SSH] opening connection to ec2-user@10.x.2.217<{:user_known_hosts_file=>"/dev/null", :port=>22, :compression=>false, :compression_level=>0, :keepalive=>true, :keepalive_interval=>60, :timeout=>10, :keys_only=>true, :keys=>["/c/Workspace/xx/automation/xx/.kitchen/default-amazon-20180810.pem"], :auth_methods=>["publickey"], :verify_host_key=>false}> Transferring files to
D TIMING: scp async upload (Kitchen::Transport::Ssh)
D Cleaning up local sandbox in /tmp/default-amazon-20180810-sandbox-20181004-1919-1a1t5sj