Guest User

Untitled

a guest
Oct 21st, 2017
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.53 KB | None | 0 0
  1. ├── Vagrantfile
  2. └── playbooks
  3. ├── inventory
  4. ├── main.yml
  5. └── vars.yml
  6.  
  7. # -*- mode: ruby -*-
  8. # vi: set ft=ruby :
  9.  
  10. Vagrant.configure(2) do |config|
  11. config.vm.box = "ubuntu/xenial64"
  12. config.ssh.insert_key = true
  13.  
  14. config.vm.provider "virtualbox" do |v|
  15. v.name = "ubuntu"
  16. v.memory = 1024
  17. v.cpus = 2
  18. end
  19.  
  20. config.vm.hostname = "ubuntu"
  21. config.vm.network :private_network, ip: "192.168.33.7"
  22.  
  23. config.vm.provision "ansible" do |ansible|
  24. ansible.playbook = "playbooks/main.yml"
  25. ansible.sudo = true
  26. ansible.verbose = true
  27. ansible.inventory_path = "playbooks/inventory"
  28. ansible.compatibility_mode = "2.0"
  29. end
  30.  
  31. end
  32.  
  33. ---
  34. - hosts: ubuntu
  35. become: yes
  36.  
  37. vars_files:
  38. - vars.yml
  39.  
  40. roles:
  41. - geerlingguy.docker
  42.  
  43. [ubuntu]
  44. 192.168.33.7
  45.  
  46. [ubuntu:vars]
  47. ansible_ssh_user=vagrant
  48. ansible_ssh_private_key_file=~/.vagrant.d/insecure_private_key
  49.  
  50. docker_edition: 'ce'
  51. docker_package: "docker-{{ docker_edition }}"
  52. docker_package_state: present
  53.  
  54. ==> default: Checking for guest additions in VM...
  55. default: The guest additions on this VM do not match the installed version of
  56. default: VirtualBox! In most cases this is fine, but in rare cases it can
  57. default: prevent things such as shared folders from working properly. If you see
  58. default: shared folder errors, please make sure the guest additions within the
  59. default: virtual machine match the version of VirtualBox you have installed on
  60. default: your host and reload your VM.
  61. default:
  62. default: Guest Additions Version: 5.0.40
  63. default: VirtualBox Version: 5.1
  64. ==> default: Setting hostname...
  65. ==> default: Configuring and enabling network interfaces...
  66. ==> default: Mounting shared folders...
  67. default: /vagrant => /Users/danilo/tutorials/ansible ubuntu
  68. ==> default: Running provisioner: ansible...
  69. default: Running ansible-playbook...
  70. PYTHONUNBUFFERED=1 ANSIBLE_FORCE_COLOR=true ANSIBLE_HOST_KEY_CHECKING=false ANSIBLE_SSH_ARGS='-o UserKnownHostsFile=/dev/null -o IdentitiesOnly=yes -o IdentityFile=/Users/danilo/tutorials/ansible ubuntu/.vagrant/machines/default/virtualbox/private_key -o ControlMaster=auto -o ControlPersist=60s' ansible-playbook --connection=ssh --timeout=30 --extra-vars=ansible_user='ubuntu' --limit="default" --inventory-file=playbooks/inventory --become -v playbooks/main.yml
  71. No config file found; using defaults
  72. ERROR! Specified --limit does not match any hosts
  73. Ansible failed to complete successfully. Any error output should be
  74. visible above. Please fix these errors and try again.
Add Comment
Please, Sign In to add comment