Effort is made to ensure a VM always have a status and Unused VM statuses are removed
This commit is contained in:
		
					parent
					
						
							
								befb22b9cb
							
						
					
				
			
			
				commit
				
					
						f3f2f6127a
					
				
			
		
					 11 changed files with 86 additions and 77 deletions
				
			
		|  | @ -27,7 +27,8 @@ author = 'ungleich' | |||
| # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom | ||||
| # ones. | ||||
| extensions = [ | ||||
|     'sphinx.ext.autodoc' | ||||
|     'sphinx.ext.autodoc', | ||||
|     'sphinx_rtd_theme', | ||||
| ] | ||||
| 
 | ||||
| # Add any paths that contain templates here, relative to this directory. | ||||
|  | @ -43,7 +44,8 @@ exclude_patterns = [] | |||
| # The theme to use for HTML and HTML Help pages.  See the documentation for | ||||
| # a list of builtin themes. | ||||
| # | ||||
| html_theme = 'alabaster' | ||||
| 
 | ||||
| html_theme = "sphinx_rtd_theme" | ||||
| 
 | ||||
| # Add any paths that contain custom static files (such as style sheets) here, | ||||
| # relative to this directory. They are copied after the builtin static files, | ||||
|  |  | |||
|  | @ -11,8 +11,10 @@ Installation | |||
| 
 | ||||
| Alpine | ||||
| ------ | ||||
| Python Wheel (Binary) Packages does not support Alpine Linux as it is using musl libc instead of glibc. | ||||
| Therefore, expect longer installation times than other linux distributions. | ||||
| 
 | ||||
| .. note:: | ||||
|     Python Wheel (Binary) Packages does not support Alpine Linux as it is using musl libc instead of glibc. | ||||
|     Therefore, expect longer installation times than other linux distributions. | ||||
| 
 | ||||
| Enable Edge Repos, Update and Upgrade | ||||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||||
|  | @ -196,34 +198,3 @@ profile e.g *~/.profile* | |||
| 
 | ||||
| and run :code:`source ~/.profile` | ||||
| 
 | ||||
| 
 | ||||
| Arch | ||||
| ----- | ||||
| 
 | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     # Update/Upgrade | ||||
|     pacman -Syuu | ||||
|     pacman -S python3 qemu chrony python-pip | ||||
| 
 | ||||
|     pip3 install pipenv | ||||
| 
 | ||||
|     cat > /etc/chrony.conf << EOF | ||||
|     server 0.arch.pool.ntp.org | ||||
|     server 1.arch.pool.ntp.org | ||||
|     server 2.arch.pool.ntp.org | ||||
|     EOF | ||||
| 
 | ||||
|     systemctl start chronyd | ||||
|     systemctl enable chronyd | ||||
| 
 | ||||
|     # Create non-root user and allow it sudo access | ||||
|     # without password | ||||
|     useradd -m ucloud | ||||
|     echo "ucloud ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers | ||||
| 
 | ||||
|     sudo -H -u ucloud bash -c 'cd /home/ucloud && git clone https://aur.archlinux.org/yay.git && cd yay && makepkg -si' | ||||
|     sudo -H -u ucloud bash -c 'yay -S etcd' | ||||
| 
 | ||||
|     systemctl start etcd | ||||
|     systemctl enable etcd | ||||
|  | @ -1,19 +1,32 @@ | |||
| TODO | ||||
| ==== | ||||
| 
 | ||||
| Security | ||||
| -------- | ||||
| 
 | ||||
| * **Check Authentication:** Nico reported that some endpoints | ||||
|   even work without providing token. (ListUserVM) | ||||
|   even work without providing token. (e.g ListUserVM) | ||||
| 
 | ||||
| Refactoring/Feature | ||||
| ------------------- | ||||
| 
 | ||||
| * Put overrides for **IMAGE_BASE**, **VM_BASE** in **ImageStorageHandler**. | ||||
| 
 | ||||
| * Put "Always use only one StorageHandler" | ||||
| 
 | ||||
| * Expose more details in ListUserFiles. | ||||
| * Throw KeyError instead of returning None when some key is not found in etcd. | ||||
| * Create Network Manager | ||||
|     * That would handle tasks like up/down an interface | ||||
|     * Create VXLANs, Bridges, TAPs. | ||||
|     * Remove them when they are no longer used. | ||||
| 
 | ||||
| * Check for :code:`etcd3.exceptions.ConnectionFailedError` when calling some etcd operation to | ||||
|   avoid crashing whole application. | ||||
| * Throw KeyError instead of returning None when some key is not found in etcd. | ||||
| * Expose more details in ListUserFiles. | ||||
| Reliability | ||||
| ----------- | ||||
| 
 | ||||
| * What to do if some command hangs forever? e.g CEPH commands | ||||
|   :code:`rbd ls ssd` etc. hangs forever if CEPH isn't running | ||||
|   or not responding. | ||||
| * What to do if etcd goes down? | ||||
| 
 | ||||
| Misc. | ||||
| ----- | ||||
| 
 | ||||
| * Put "Always use only one StorageHandler" | ||||
|  |  | |||
|  | @ -69,21 +69,49 @@ Then, launch your remote desktop client and connect to vnc://localhost:1234. | |||
| Create Network | ||||
| -------------- | ||||
| 
 | ||||
| Layer 2 Network with sample IPv6 range fd00::/64 (without IPAM and routing) | ||||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     ucloud-cli network create --network-name mynet --network-type vxlan | ||||
| 
 | ||||
| 
 | ||||
| .. code-block:: json | ||||
| Layer 2 Network with /64 network with automatic IPAM | ||||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     { | ||||
|         "message": "Network successfully added." | ||||
|     } | ||||
|     ucloud-cli network create --network-name mynet --network-type vxlan --user True | ||||
| 
 | ||||
| Create VM using this network | ||||
| Attach Network to VM | ||||
| -------------------- | ||||
| 
 | ||||
| Currently, user can only attach network to his/her VM at | ||||
| the time of creation. A sample command to create VM with | ||||
| a network is as follow | ||||
| 
 | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     ucloud-cli vm create --vm-name meow2 --cpu 1 --ram '1gb' --os-ssd '4gb' --image images:alpine --network mynet | ||||
| 
 | ||||
| .. _get-list-of-hosts: | ||||
| 
 | ||||
| Get List of Hosts | ||||
| ----------------- | ||||
| 
 | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     ucloud-cli host list | ||||
| 
 | ||||
| 
 | ||||
| Migrate VM | ||||
| ---------- | ||||
| 
 | ||||
| .. code-block:: sh | ||||
| 
 | ||||
|     ucloud-cli vm migrate --vm-name meow --destination server1.place10 | ||||
| 
 | ||||
| 
 | ||||
| .. option:: --destination | ||||
| 
 | ||||
|    The name of destination host. You can find a list of host | ||||
|    using :ref:`get-list-of-hosts` | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue