vagrantfile

Building the RISC-V GNU toolchain - recommended Vagrant configuration?

老子叫甜甜 提交于 2019-12-24 15:02:09
问题 I have tried and failed a few times to install the riscv-gnu-toolchain into a virtual machine. Does anyone have a suggested Linux / virtual machine configuration (ideally a Vagrantfile)? If I can't find one, I'll make one myself and share it here. Starting OS version, memory and hard-drive capacity - ideally non-GUI, and as minimal as makes sense. Also, since it's such a huge build, are people having luck with multi-CPU setups and make -j6 (or your core-count) for parallel builds? 回答1: This

Uninstalling vagrant-proxyconf doesn't remove proxy settings

这一生的挚爱 提交于 2019-12-24 11:19:33
问题 I installed vagrant-proxyconf and added to Vagrantfile the following: if Vagrant.has_plugin?("vagrant-proxyconf") config.proxy.http = "http://192.168.33.10:3128/" config.proxy.https = "http://192.168.33.10:3128/" end Later I uninstalled vagrant-proxyconf and removed the above lines from Vagrantfile. Now every time I try to use apt-get or npm i , I get this error message: Failed to connect to 192.168.33.10 port 3128: Connection refused So the proxy settings are still somewhere within the

How to run an ansible playbook on a specific vagrant host

最后都变了- 提交于 2019-12-24 11:09:59
问题 I have a Vagrantfile which creates 3 servers. I have two ansible playbooks. playbook1 should be executed on every server first. The second playbook2 should only be executed on server1 and not on server2 and server3. How can I manage this with my Vagrantfile? Vagrant.configure("2") do |config| config.vm.box = "ubuntu/bionic64" config.vm.define "server1" do |server1| // end config.vm.define "server2" do |server2| // end config.vm.define "server3" do |server3| // end config.vm.provision "ansible

Homestead cant access second site remotely

瘦欲@ 提交于 2019-12-23 08:57:36
问题 I have one site setup fine, but the second can't be accessed remotely: My YAML: --- ip: "192.168.10.10" memory: 2048 cpus: 1 provider: virtualbox authorize: ~/.ssh/id_rsa.pub keys: - ~/.ssh/id_rsa folders: - map: ~/Projects to: /home/vagrant/Projects sites: - map: app.app to: /home/vagrant/sites/app1/public - map: app2.app to: /home/vagrant/sites/app2/public port: 8100 ports: - host: 81 - guest: 8100 I can access the first site using my IP easily - http://192.168.0.5/ but the second one

Run Python script in Vagrant

亡梦爱人 提交于 2019-12-23 03:47:15
问题 This is a dumb question but please help me. Q. How do I run Python script that is saved in my local machine? after vagrant up and vagrant ssh , I do not see any Python file in the VM. Then what if I want to run Python scripts that are saved in my Mac? I do not want to copy and paste them manually using vim. How would you run Python script in Vagrant ssh? 回答1: On your Guest OS there will be a folder under / called /vagrant/ this will be all the files and directories under the directory on your

Why won't Ansible mount Vagrant remote NFS share

混江龙づ霸主 提交于 2019-12-23 03:08:31
问题 My Ansible playbook is raising an error when I try to execute the mount module: Error mounting 192.168.33.1:/Users/me/playbooks/site1/website: mount.nfs: remote share not in 'host:dir' format The code directory is mounted: $ vagrant ssh -c "mount | grep http" 192.168.33.1:/Users/me/playbooks/site1/website on /srv/http/site1.com type nfs (...) Vagrantfile: Vagrant.configure("2") do |config| config.vm.box = "debian/jessie64" config.vm.network "forwarded_port", guest: 80, host: 8080 config.vm

How to switch order of network adapters in Vagrant under VirtualBox?

心已入冬 提交于 2019-12-22 13:47:12
问题 Under Vagrant I have config something like this: Vagrant.configure(2) do |config| config.vm.box = "ubuntu/trusty64" config.vm.provider "virtualbox" do |vb| vb.memory = "512" end config.vm.host_name = 'core.example.com' config.vm.network "forwarded_port", guest: 22, host: 2222, id: 'ssh' config.vm.network "private_network", ip: '172.28.128.3' config.vm.synced_folder "./vagrant_core", "/vagrant", create: true end And after this I receiving something like that: Adapter eth0 -> NAT Adapter eth1 -

Store Vagrant VM in custom folder

只谈情不闲聊 提交于 2019-12-22 03:46:10
问题 I want to specify folder where Vagrant will store my VM. I need it only for one VM, so I don't want to modify VirtualBox.xml defaultMachineFolder or change VBOX_USER_HOME environment variable. What is the right way to do it in Vagrantfile? I've already tried to add the following lines: config.vm.provider "virtualbox" do |vb| vb.customize ["createvm", "--name", "name", "--basefolder", "path"] end It creates VM folder on the path I specified, but it also duplicate it in the ~/VirtualBox VMs

Store Vagrant VM in custom folder

只谈情不闲聊 提交于 2019-12-22 03:45:13
问题 I want to specify folder where Vagrant will store my VM. I need it only for one VM, so I don't want to modify VirtualBox.xml defaultMachineFolder or change VBOX_USER_HOME environment variable. What is the right way to do it in Vagrantfile? I've already tried to add the following lines: config.vm.provider "virtualbox" do |vb| vb.customize ["createvm", "--name", "name", "--basefolder", "path"] end It creates VM folder on the path I specified, but it also duplicate it in the ~/VirtualBox VMs

Cannot make outbound HTTP Requests from vagrant VM

余生长醉 提交于 2019-12-21 03:58:34
问题 I am unable to connect to the internet from within a Vagrant virtual machine I have set up. For example, at the root, when I type: curl http://google.com It fails with the message: curl: (6) Couldn't resolve host 'google.com' I'm not sure if it's a firewall setting, although as far as I know I have not created any firewall rules for port 80 or any other port. Here is the relevant section of my Vagrantfile. If there is any other information I can provide please let me know in the comments: