github.com/dahs81/otto@v0.2.1-0.20160126165905-6400716cf085/builtin/app/go/data/common/dev-dep/Vagrantfile.fragment.tpl (about) 1 # Generated by dependency for development: {{ name }} 2 3 ${{ name }}_setup = <<COPY 4 # Copy our binary 5 sudo mv /tmp/dep-{{ name }} {{ dep_binary_path }} 6 7 # Copy the upstart file 8 sudo mv /tmp/dep-{{ name }}.upstart.conf /etc/init/{{ name }}.conf 9 10 # Start it! 11 sudo start {{ name }} 12 COPY 13 14 # Sync our own dep folder in there 15 config.vm.synced_folder "{{ path.working }}", "{{ path.guest_working }}" 16 17 # Copy files into a temp directory. The script will move them. 18 config.vm.provision "file", 19 source: "{{ path.cache }}/dev-dep-output", 20 destination: "/tmp/dep-{{ name }}" 21 22 config.vm.provision "file", 23 source: "{{ path.compiled }}/dev-dep/upstart.conf", 24 destination: "/tmp/dep-{{ name }}.upstart.conf" 25 26 config.vm.provision "shell", 27 inline: ${{ name }}_setup 28 29 # Foundation configuration for dev dep 30 {% for dir in foundation_dirs.dev_dep %} 31 dir = "/otto/foundation-{{ name }}-{{ forloop.Counter }}" 32 config.vm.synced_folder "{{ dir }}", dir 33 config.vm.provision "shell", inline: "cd #{dir} && bash #{dir}/main.sh" 34 {% endfor %}