Added Vagrantfile and altered documentation
This commit is contained in:
parent
e08b153732
commit
d8b61b0eca
2 changed files with 53 additions and 0 deletions
|
@ -100,6 +100,14 @@ It downloads the latest version of ZeroNet then starts it automatically.
|
||||||
* `pip install gevent msgpack-python`
|
* `pip install gevent msgpack-python`
|
||||||
* [Download](https://github.com/HelloZeroNet/ZeroNet/archive/master.zip), Unpack, run `python zeronet.py`
|
* [Download](https://github.com/HelloZeroNet/ZeroNet/archive/master.zip), Unpack, run `python zeronet.py`
|
||||||
|
|
||||||
|
### Vagrant
|
||||||
|
|
||||||
|
* `vagrant up`
|
||||||
|
* Access VM with `vagrant ssh`
|
||||||
|
* `cd /vagrant`
|
||||||
|
* Run `python zeronet.py --ui_ip 0.0.0.0`
|
||||||
|
* Open http://127.0.0.1:43110/ in your browser
|
||||||
|
|
||||||
## Current limitations
|
## Current limitations
|
||||||
|
|
||||||
* No torrent-like, file splitting for big file support
|
* No torrent-like, file splitting for big file support
|
||||||
|
|
45
Vagrantfile
vendored
Normal file
45
Vagrantfile
vendored
Normal file
|
@ -0,0 +1,45 @@
|
||||||
|
# -*- mode: ruby -*-
|
||||||
|
# vi: set ft=ruby :
|
||||||
|
|
||||||
|
VAGRANTFILE_API_VERSION = "2"
|
||||||
|
|
||||||
|
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
|
||||||
|
|
||||||
|
#Set box
|
||||||
|
config.vm.box = "ubuntu/trusty64"
|
||||||
|
|
||||||
|
#Do not check fo updates
|
||||||
|
config.vm.box_check_update = false
|
||||||
|
|
||||||
|
#Add private network
|
||||||
|
config.vm.network "private_network", type: "dhcp"
|
||||||
|
|
||||||
|
#Redirect ports
|
||||||
|
config.vm.network "forwarded_port", guest: 43110, host: 43110
|
||||||
|
config.vm.network "forwarded_port", guest: 15441, host: 15441
|
||||||
|
|
||||||
|
#Sync folder using NFS if not windows
|
||||||
|
config.vm.synced_folder ".", "/vagrant",
|
||||||
|
:nfs => !Vagrant::Util::Platform.windows?
|
||||||
|
|
||||||
|
#Virtal Box settings
|
||||||
|
config.vm.provider "virtualbox" do |vb|
|
||||||
|
# Don't boot with headless mode
|
||||||
|
#vb.gui = true
|
||||||
|
|
||||||
|
# Set VM settings
|
||||||
|
vb.customize ["modifyvm", :id, "--memory", "512"]
|
||||||
|
vb.customize ["modifyvm", :id, "--cpus", 1]
|
||||||
|
end
|
||||||
|
|
||||||
|
#Update system
|
||||||
|
config.vm.provision "shell",
|
||||||
|
inline: "sudo apt-get update -y && sudo apt-get upgrade -y"
|
||||||
|
|
||||||
|
#Install deps
|
||||||
|
config.vm.provision "shell",
|
||||||
|
inline: "sudo apt-get install msgpack-python python-gevent python-pip -y"
|
||||||
|
config.vm.provision "shell",
|
||||||
|
inline: "sudo pip install msgpack-python --upgrade"
|
||||||
|
|
||||||
|
end
|
Loading…
Reference in a new issue