1
0

basic.rst 941 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. Salt Cloud basic usage
  2. ======================
  3. Salt Cloud needs, at least, one configured
  4. :ref:`Provider <cloud-provider-specifics>`
  5. and :ref:`Profile <salt-cloud-profiles>` to be functional.
  6. Creating a VM
  7. -------------
  8. To create a VM with salt cloud, use command:
  9. .. code-block:: bash
  10. salt-cloud -p <profile> name_of_vm
  11. Assuming there is a profile configured as following:
  12. .. code-block:: bash
  13. fedora_rackspace:
  14. provider: my-rackspace-config
  15. image: Fedora 17
  16. size: 256 server
  17. script: bootstrap-salt
  18. Then, the command to create new VM named ``fedora_http_01`` is:
  19. .. code-block:: bash
  20. salt-cloud -p fedora_rackspace fedora_http_01
  21. Destroying a VM
  22. ---------------
  23. To destroy a created-by-salt-cloud VM, use command:
  24. .. code-block:: bash
  25. salt-cloud -d name_of_vm
  26. For example, to delete the VM created on above example, use:
  27. .. code-block:: bash
  28. salt-cloud -d fedora_http_01