Skip to content

Provisioning vagrant from within the vagrant machine #124

Open

Description

@AntJanus

Genesis used to have a ./bin/provision script that ran the Ansible playbooks from within the machine. This made it really easy to port over to Windows (there are a few other changes I had to make to genesis but nothing major); however, Ansible is completely unsupported on Windows.

I guess my question is what would be the appropriate script to run all this from within Vagrant?

Activity

  1. EvanK commented on Jun 23, 2016

    @EvanK
    Contributor

    Because there are several steps that ansible handles transparently (some as part of the vagrant provision process), I don't know that this would work on windows...but you could try bringing the machine up without provisioning:

    vagrant up --no-provision
    

    And then run the playbooks manually from within the vm as the vagrant user:

    ansible-playbook -e stage=local --user=vagrant --ask-pass --ask-sudo-pass /vagrant/lib/ansible/provision.yml
    
  2. AntJanus commented on Jun 23, 2016

    @AntJanus
    ContributorAuthor

    Ah! That's what I was asking, how I could run this within the VM. I'll test this out and let you know! :) I've got the original Genesis working locally (except for capistrano/ruby nightmare) so when I migrate over to evolution, I'll try to document what I had to do!

  3. EvanK commented on Jun 24, 2016

    @EvanK
    Contributor

    Alternatively, you may want to try using ansible via cygwin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions