2016-06-06 18:51:39 +02:00
|
|
|
phpVirtualBox
|
|
|
|
=============
|
|
|
|
|
2016-06-14 10:32:44 +02:00
|
|
|
This is a fork of [jazzdd86/phpvirtualbox](https://hub.docker.com/r/jazzdd/phpvirtualbox/).
|
|
|
|
|
2016-06-06 18:51:39 +02:00
|
|
|
[phpVirtualBox][1] is a web-based front-end to VirtualBox written in PHP.
|
|
|
|
|
|
|
|
### docker-compose.yml
|
|
|
|
|
|
|
|
```yaml
|
|
|
|
phpvirtualbox:
|
2016-06-14 10:32:44 +02:00
|
|
|
image: vimagick/phpvirtualbox
|
2016-06-06 18:51:39 +02:00
|
|
|
ports:
|
|
|
|
- "8888:80"
|
|
|
|
environment:
|
|
|
|
- ID_PORT_18083_TCP=remote-server:18083
|
|
|
|
- ID_NAME=Vbox
|
|
|
|
- ID_USER=username
|
|
|
|
- ID_PW=password
|
|
|
|
- CONF_browserRestrictFolders=/data,
|
|
|
|
restart: always
|
|
|
|
```
|
|
|
|
|
|
|
|
> - Make sure you can login `remote-server` with `username:password`.
|
2016-06-14 10:32:44 +02:00
|
|
|
> - ISO images can be placed at `/data` directory on `remote-server`.
|
2016-06-09 17:41:17 +02:00
|
|
|
> - During the OS installation, you can connect to it with RDP viewer.
|
2016-06-06 18:51:39 +02:00
|
|
|
|
|
|
|
### vboxweb.service
|
|
|
|
|
|
|
|
```
|
|
|
|
# /etc/systemd/system/vboxweb.service
|
|
|
|
[Unit]
|
|
|
|
Description=VirtualBox Web Service
|
|
|
|
After=network.target
|
|
|
|
|
|
|
|
[Service]
|
|
|
|
ExecStart=/usr/bin/vboxwebsrv -H 0.0.0.0 -p 18083
|
|
|
|
Restart=on-failure
|
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|
|
|
|
```
|
|
|
|
|
|
|
|
### server setup
|
|
|
|
|
|
|
|
```bash
|
|
|
|
# install virtualbox
|
2016-07-21 08:52:02 +02:00
|
|
|
echo "deb http://download.virtualbox.org/virtualbox/debian $(lsb_release -cs) contrib" > /etc/apt/sources.list.d/virtualbox.list
|
2016-06-14 09:50:04 +02:00
|
|
|
wget -O- http://download.virtualbox.org/virtualbox/debian/oracle_vbox_2016.asc | apt-key add -
|
2016-06-06 18:51:39 +02:00
|
|
|
apt-get update
|
2016-07-21 08:52:02 +02:00
|
|
|
apt-get install -y virtualbox-5.1 dkms
|
2016-06-06 18:51:39 +02:00
|
|
|
systemctl status vboxdrv
|
|
|
|
|
|
|
|
# install extpack
|
2016-07-21 08:52:02 +02:00
|
|
|
wget http://download.virtualbox.org/virtualbox/5.1.0/Oracle_VM_VirtualBox_Extension_Pack-5.1.0-108711.vbox-extpack
|
|
|
|
VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-5.1.0-108711.vbox-extpack
|
2016-06-06 18:51:39 +02:00
|
|
|
VBoxManage list extpacks
|
|
|
|
|
|
|
|
# install vagrant
|
2016-07-21 08:52:02 +02:00
|
|
|
wget https://releases.hashicorp.com/vagrant/1.8.5/vagrant_1.8.5_x86_64.deb
|
|
|
|
dpkg -i vagrant_1.8.5_x86_64.deb
|
2016-06-06 18:51:39 +02:00
|
|
|
vagrant version
|
|
|
|
|
|
|
|
# start vm
|
2016-06-14 09:50:04 +02:00
|
|
|
vagrant box add debian/jessie64
|
2016-06-06 18:51:39 +02:00
|
|
|
vagrant init debian/jessie64
|
|
|
|
vagrant up
|
|
|
|
|
|
|
|
# disable vboxweb-service
|
|
|
|
systemctl stop vboxweb-service
|
|
|
|
systemctl disable vboxweb-service
|
|
|
|
|
|
|
|
# enable vboxweb
|
|
|
|
systemctl daemon-reload
|
|
|
|
systemctl start vboxweb
|
|
|
|
systemctl enable vboxweb
|
|
|
|
```
|
|
|
|
|
|
|
|
[1]: http://sourceforge.net/projects/phpvirtualbox/
|