summaryrefslogtreecommitdiffstats
path: root/docs/reference/vppvagrant/boxSetup.rst
diff options
context:
space:
mode:
authorNathan Skrzypczak <nathan.skrzypczak@gmail.com>2021-08-19 11:38:06 +0200
committerDave Wallace <dwallacelf@gmail.com>2021-10-13 23:22:32 +0000
commit9ad39c026c8a3c945a7003c4aa4f5cb1d4c80160 (patch)
tree3cca19635417e28ae381d67ae31c75df2925032d /docs/reference/vppvagrant/boxSetup.rst
parentf47122e07e1ecd0151902a3cabe46c60a99bee8e (diff)
docs: better docs, mv doxygen to sphinx
This patch refactors the VPP sphinx docs in order to make it easier to consume for external readers as well as VPP developers. It also makes sphinx the single source of documentation, which simplifies maintenance and operation. Most important updates are: - reformat the existing documentation as rst - split RELEASE.md and move it into separate rst files - remove section 'events' - remove section 'archive' - remove section 'related projects' - remove section 'feature by release' - remove section 'Various links' - make (Configuration reference, CLI docs, developer docs) top level items in the list - move 'Use Cases' as part of 'About VPP' - move 'Troubleshooting' as part of 'Getting Started' - move test framework docs into 'Developer Documentation' - add a 'Contributing' section for gerrit, docs and other contributer related infos - deprecate doxygen and test-docs targets - redirect the "make doxygen" target to "make docs" Type: refactor Change-Id: I552a5645d5b7964d547f99b1336e2ac24e7c209f Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Diffstat (limited to 'docs/reference/vppvagrant/boxSetup.rst')
-rw-r--r--docs/reference/vppvagrant/boxSetup.rst122
1 files changed, 0 insertions, 122 deletions
diff --git a/docs/reference/vppvagrant/boxSetup.rst b/docs/reference/vppvagrant/boxSetup.rst
deleted file mode 100644
index ed20c9d37c1..00000000000
--- a/docs/reference/vppvagrant/boxSetup.rst
+++ /dev/null
@@ -1,122 +0,0 @@
-.. _boxSetup:
-
-.. toctree::
-
-
-Vagrantfiles
-============
-
-A `Vagrantfile <https://www.vagrantup.com/docs/vagrantfile/>`_ contains the box and provision configuration settings for your VM. The syntax of Vagrantfiles is Ruby (Ruby experience is not necessary).
-
-The command **vagrant up** creates a *Vagrant Box* based on your Vagrantfile. A Vagrant box is one of the motivations for using Vagrant - its a "development-ready box" that can be copied to other machines to recreate the same environment.
-
-It's common for people to think that a Vagrant box *is* the VM. But rather, the VM is *inside* a Vagrant box, with the box containing additional configuration options you can set, such as VM options, scripts to run on boot, etc.
-
-This `Vagrant website for boxes <https://app.vagrantup.com/boxes/search>`_ shows you how to configure a basic Vagrantfile for your specific OS and VM software.
-
-
-Box configuration
-_________________
-
-
-Looking at the :ref:`vppVagrantfile`, we can see that the default OS is Ubuntu 16.04 (since the variable *distro* equals *ubuntu1604* if there is no VPP_VAGRANT_DISTRO variable set - thus the **else** case is executed.)
-
-.. code-block:: ruby
-
- # -*- mode: ruby -*-
- # vi: set ft=ruby :
-
- Vagrant.configure(2) do |config|
-
- # Pick the right distro and bootstrap, default is ubuntu1604
- distro = ( ENV['VPP_VAGRANT_DISTRO'] || "ubuntu1604")
- if distro == 'centos7'
- config.vm.box = "centos/7"
- config.vm.box_version = "1708.01"
- config.ssh.insert_key = false
- else
- config.vm.box = "puppetlabs/ubuntu-16.04-64-nocm"
-
-As mentioned in the previous page, you can specify which OS and VM provider you want for your Vagrant box from the `Vagrant boxes page <https://app.vagrantup.com/boxes/search>`_, and setting your ENV variable appropriately in *env.sh*.
-
-Next in the Vagrantfile, you see some *config.vm.provision* commands. As paraphrased from `Basic usage of Provisioners <https://www.vagrantup.com/docs/provisioning/basic_usage.html>`_, by default these are only run *once* - during the first boot of the box.
-
-.. code-block:: ruby
-
- config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"update.sh")
- config.vm.provision :shell, :path => File.join(File.dirname(__FILE__),"build.sh"), :args => "/vpp vagrant"
-
-The two lines above set the VM to run two scripts during its first bootup: an update script *update.sh* that does basic updating and installation of some useful tools, as well as *build.sh* that builds (but does **not** install) VPP in the VM. You can view these scripts on your own for more detail on the commands used.
-
-
-Looking further in the :ref:`vppVagrantfile`, you can see more Ruby variables being set to ENV's or to a default value:
-
-.. code-block:: ruby
-
- # Define some physical ports for your VMs to be used by DPDK
- nics = (ENV['VPP_VAGRANT_NICS'] || "2").to_i(10)
- for i in 1..nics
- config.vm.network "private_network", type: "dhcp"
- end
-
- # use http proxy if available
- if ENV['http_proxy'] && Vagrant.has_plugin?("vagrant-proxyconf")
- config.proxy.http = ENV['http_proxy']
- config.proxy.https = ENV['https_proxy']
- config.proxy.no_proxy = "localhost,127.0.0.1"
- end
-
- vmcpu=(ENV['VPP_VAGRANT_VMCPU'] || 2)
- vmram=(ENV['VPP_VAGRANT_VMRAM'] || 4096)
-
-
-You can see how the box or VM is configured, such as the amount of NICs (defaults to 3 NICs: 1 x NAT - host access and 2 x VPP DPDK enabled), CPUs (defaults to 2), and RAM (defaults to 4096 MB).
-
-
-Box bootup
-__________
-
-
-Once you're satisfied with your *Vagrantfile*, boot the box with:
-
-.. code-block:: shell
-
- $ vagrant up
-
-Doing this above command will take quite some time, since you are installing a VM and building VPP. Take a break and get some scooby snacks while you wait.
-
-To confirm it is up, show the status and information of Vagrant boxes with:
-
-.. code-block:: console
-
- $ vagrant global-status
- id name provider state directory
- -----------------------------------------------------------------------------------------
- d90a17b default virtualbox poweroff /home/centos/andrew-vpp/vppsb/vpp-userdemo
- 77b085e default virtualbox poweroff /home/centos/andrew-vpp/vppsb2/vpp-userdemo
- c1c8952 default virtualbox poweroff /home/centos/andrew-vpp/testingVPPSB/extras/vagrant
- c199140 default virtualbox running /home/centos/andrew-vpp/vppsb3/vpp-userdemo
-
- You will have only one machine running, but I have multiple as shown above.
-
-.. note::
-
- To poweroff your VM, type:
-
- .. code-block:: shell
-
- $ vagrant halt <id>
-
- To resume your VM, type:
-
- .. code-block:: shell
-
- $ vagrant resume <id>
-
- To destroy your VM, type:
-
- .. code-block:: shell
-
- $ vagrant destroy <id>
-
- Note that "destroying" a VM does not erase the box, but rather destroys all resources allocated for that VM. For other Vagrant commands, such as destroying a box, refer to the `Vagrant CLI Page <https://www.vagrantup.com/docs/cli/>`_.