1
0

function.rst 1.1 KB

123456789101112131415161718192021222324252627282930
  1. .. _salt-cloud-functions:
  2. ===============
  3. Cloud Functions
  4. ===============
  5. Cloud functions work much the same way as cloud actions, except that they don't
  6. perform an operation on a specific instance, and so do not need a machine name
  7. to be specified. However, since they perform an operation on a specific cloud
  8. provider, that provider must be specified.
  9. .. code-block:: bash
  10. $ salt-cloud -f show_image ec2 image=ami-fd20ad94
  11. There are three universal salt-cloud functions that are extremely useful for
  12. gathering information about instances on a provider basis:
  13. * ``list_nodes``: Returns some general information about the instances for the given provider.
  14. * ``list_nodes_full``: Returns all information about the instances for the given provider.
  15. * ``list_nodes_select``: Returns select information about the instances for the given provider.
  16. .. code-block:: bash
  17. $ salt-cloud -f list_nodes linode
  18. $ salt-cloud -f list_nodes_full linode
  19. $ salt-cloud -f list_nodes_select linode
  20. Another useful reference for viewing ``salt-cloud`` functions is the
  21. :ref:`Salt Cloud Feature Matrix <salt-cloud-feature-matrix>`.