WIP: run-in-vagrant

This commit is contained in:
Cristi Ene 2021-10-07 10:36:13 +03:00
parent aef60aae17
commit a10ef5848b
5 changed files with 1785 additions and 24 deletions

.gitignore vendored
View File

@ -3,4 +3,5 @@ node_modules

View File

@ -175,6 +175,12 @@ Steps to do in VM:
NODE_TLS_REJECT_UNAUTHORIZED='0' node ./index.js --path="./config/dev/"
Install plugin for virtual box guest additions:
vagrant plugin install vagrant-vbguest
### Problems / to do
It worked once but now it does not work, don't know why.

Vagrantfile vendored
View File

@ -12,7 +12,10 @@ Vagrant.configure("2") do |config|
# Every Vagrant development environment requires a box. You can search for
# boxes at https://vagrantcloud.com/search.
config.vm.box = "bento/ubuntu-16.04"
# config.vm.box = "bento/ubuntu-16.04"
config.vm.box = "ubuntu/impish64"
# config.vm.box = "ubuntu/xenial64"
# Disable automatic box update checking. If you disable this, then
# boxes will only be checked for updates when the user runs
@ -31,7 +34,7 @@ Vagrant.configure("2") do |config|
# config.vm.network "forwarded_port", guest: 80, host: 8080, host_ip: ""
# Create a private network, which allows host-only access to the machine
# using a specific IP.
# using a specific IP
# config.vm.network "private_network", ip: ""
# Create a public network, which generally matched to bridged network.
@ -39,7 +42,7 @@ Vagrant.configure("2") do |config|
# your network.
config.vm.network "public_network"
config.ssh.forward_x11 = true
# config.ssh.forward_x11 = true
config.ssh.forward_agent = true
# Share an additional folder to the guest VM. The first argument is
@ -55,11 +58,11 @@ Vagrant.configure("2") do |config|
config.vm.provider "virtualbox" do |vb|
# Display the VirtualBox GUI when booting the machine
# vb.gui = true
vb.customize [
"modifyvm", :id,
"--audio", "coreaudio",
"--audiocontroller", "hda"
# vb.customize [
# "modifyvm", :id,
# "--audio", "coreaudio",
# "--audiocontroller", "hda"
# ]
# Customize the amount of memory on the VM:
vb.memory = "1024"
@ -71,9 +74,15 @@ Vagrant.configure("2") do |config|
# Enable provisioning with a shell script. Additional provisioners such as
# Ansible, Chef, Docker, Puppet and Salt are also available. Please see the
# documentation for more information about their specific syntax and use.
# config.vm.provision "shell", inline: <<-SHELL
# apt-get update
# apt-get install -y apache2
config.vm.provision "shell", path: "install.sh", privileged: true
config.vm.provision "shell", inline: <<-SHELL
apt-get update
apt install docker.io
systemctl enable --now docker
systemctl status docker
sudo groupadd docker
sudo usermod -aG docker $USER
docker --version
docker run hello-world
# config.vm.provision "shell", path: "install.sh", privileged: true

View File

@ -7,8 +7,13 @@ apt-get install -y curl
apt-get install -y python-minimal
curl -sL https://deb.nodesource.com/setup_8.x | bash
apt-get install -y nodejs
sudo apt install -y alsa-utils
sudo apt-get install -y libasound2-dev
sudo npm i -g node-gyp
apt install -y alsa-utils
apt-get install -y libasound2-dev
npm i -g node-gyp
apt install -y alsa-base pulseaudio
mkdir simulator
mkdir simulator
cp -r /vagrant/* ~/simulator/
cd simulator
sudo chmod -R 755 *
sudo chown -R vagrant:vagrant *

package-lock.json generated

File diff suppressed because it is too large Load Diff