Error: 'PlaybookCLI' object has no attribute 'options'

I attempted to run vagrant up and I got the following:

Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'bento/ubuntu-18.04'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'bento/ubuntu-18.04' version '201906.18.0' is up to date...
==> default: Setting the name of the VM: example.com
==> default: Pruning invalid NFS exports. Administrator privileges will be required...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
    default: Adapter 2: hostonly
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: 
    default: Vagrant insecure key detected. Vagrant will automatically replace
    default: this with a newly generated keypair for better security.
    default: 
    default: Inserting generated public key within guest...
    default: Removing insecure key from the guest if it's present...
    default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
    default: The guest additions on this VM do not match the installed version of
    default: VirtualBox! In most cases this is fine, but in rare cases it can
    default: prevent things such as shared folders from working properly. If you see
    default: shared folder errors, please make sure the guest additions within the
    default: virtual machine match the version of VirtualBox you have installed on
    default: your host and reload your VM.
    default: 
    default: Guest Additions Version: 6.0.8
    default: VirtualBox Version: 5.2
==> default: Setting hostname...
==> default: Configuring and enabling network interfaces...
==> default: Exporting NFS shared folders...
==> default: Preparing to edit /etc/exports. Administrator privileges will be required...
==> default: Mounting NFS shared folders...
==> default: Mounting shared folders...
    default: /vagrant => /Users/john/sites/example.com/trellis
==> default: Checking for bindfs in VM...
    default: Package manager detected: apt-get
    default: Fuse kernel module is installed
    default: Fuse kernel module is loaded
==> default: Bindfs seems to not be installed on the virtual machine, installing now
    default: Bindfs 1.13.7 is installed
==> default: Machine is ready to use bindfs!
==> default: Creating bind mounts after synced_folders...
    default: /vagrant-nfs-example.com => /srv/www/example.com/current
    default: /ansible-nfs => /home/vagrant/trellis
    default: /home/vagrant/trellis/bin => /home/vagrant/trellis/bin
==> default: [vagrant-hostmanager:guests] Updating hosts file on active guest virtual machines...
==> default: [vagrant-hostmanager:host] Updating hosts file on your workstation (password may be required)...
==> default: Running provisioner: ansible...
    default: Running ansible-galaxy...
- downloading role 'composer', owned by geerlingguy
- downloading role from https://github.com/geerlingguy/ansible-role-composer/archive/1.7.0.tar.gz
- extracting composer to /Users/john/sites/example.com/trellis/vendor/roles/composer
- composer (1.7.0) was installed successfully
- downloading role 'ntp', owned by geerlingguy
- downloading role from https://github.com/geerlingguy/ansible-role-ntp/archive/1.6.0.tar.gz
- extracting ntp to /Users/john/sites/example.com/trellis/vendor/roles/ntp
- ntp (1.6.0) was installed successfully
- downloading role 'logrotate', owned by nickhammond
- downloading role from https://github.com/nickhammond/ansible-logrotate/archive/v0.0.5.tar.gz
- extracting logrotate to /Users/john/sites/example.com/trellis/vendor/roles/logrotate
- logrotate (v0.0.5) was installed successfully
- downloading role 'swapfile', owned by oefenweb
- downloading role from https://github.com/Oefenweb/ansible-swapfile/archive/v2.0.6.tar.gz
- extracting swapfile to /Users/john/sites/example.com/trellis/vendor/roles/swapfile
- swapfile (v2.0.6) was installed successfully
- downloading role 'mailhog', owned by geerlingguy
- downloading role from https://github.com/geerlingguy/ansible-role-mailhog/archive/2.1.3.tar.gz
- extracting mailhog to /Users/john/sites/example.com/trellis/vendor/roles/mailhog
- mailhog (2.1.3) was installed successfully
- adding dependency: geerlingguy.daemonize
- downloading role 'daemonize', owned by geerlingguy
- downloading role from https://github.com/geerlingguy/ansible-role-daemonize/archive/1.2.1.tar.gz
- extracting geerlingguy.daemonize to /Users/john/sites/example.com/trellis/vendor/roles/geerlingguy.daemonize
- geerlingguy.daemonize (1.2.1) was installed successfully
    default: Running ansible-playbook...
ERROR! Unexpected Exception, this is probably a bug: 'PlaybookCLI' object has no attribute 'options'

I then ran the following on my host:

touch ~/.ssh/config
chmod 600 ~/.ssh/config

As instructed by the topic similar to it.
I then ran vagrant up immediately to get this:

Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'bento/ubuntu-18.04' version '201906.18.0' is up to date...
==> default: [vagrant-hostmanager:guests] Updating hosts file on active guest virtual machines...
==> default: [vagrant-hostmanager:host] Updating hosts file on your workstation (password may be required)...
==> default: Machine already provisioned. Run `vagrant provision` or use the `--provision`
==> default: flag to force provisioning. Provisioners marked to run always will still run.
==> default: Running action triggers after up ...
==> default: Running trigger...
==> default: Adding vagrant ssh-config for example.com to ~/.ssh/config

==> default: Machine 'default' has a post `vagrant up` message. This is a message
==> default: from the creator of the Vagrantfile, and not from Vagrant itself:
==> default: 
==> default: Your Trellis Vagrant box is ready to use!
==> default: * Composer and WP-CLI commands need to be run on the virtual machine
==> default:   for any post-provision modifications.
==> default: * You can SSH into the machine with `vagrant ssh`.
==> default: * Then navigate to your WordPress sites at `/srv/www`
==> default:   or to your Trellis files at `/home/vagrant/trellis`.

I couldn’t access the site at http://example.test, so I ran the following:

vagrant provision

It resulted in the same output with the error.

My wordpress_sites.yml:

wordpress_sites:
  example.test:
    site_hosts:
      - canonical: example.test
        redirects:
          - www.example.test
    local_path: ../site
    admin_email: admin@example.test
    multisite:
      enabled: false
    ssl:
      enabled: true
      provider: self-signed
    cache:
      enabled: false

Update: I just set up the project again by downloading trellis and bedrock, then run vagrant up from the trellis directory. It gave me the same error. Does it have to do with my SSH folder? I’m running the setup on OS X 10.14.

Another Update: Just tried to run vagrant up with the Example Project and I got the same exact result.

I’m trying to figure out what’s wrong, but I don’t know how to traceback the error or know where to look or begin. I read around that it might have to do with the roles or the latest version of ansible, but I’m not sure how to change it in the vagrant machine.

This topic was automatically closed after 42 days. New replies are no longer allowed.