# salt.cloud.clouds.tencentcloud

## Tencent Cloud Cloud Module

Added in version 3000.

The Tencent Cloud Cloud Module is used to control access to the Tencent Cloud instance. https://intl.cloud.tencent.com/

To use this module, set up the cloud configuration at

  `/etc/salt/cloud.providers` or `/etc/salt/cloud.providers.d/*.conf`:

    my-tencentcloud-config:
      driver: tencentcloud
      # Tencent Cloud Secret Id
      id: AKIDA64pOio9BMemkApzevX0HS169S4b750A
      # Tencent Cloud Secret Key
      key: 8r2xmPn0C5FDvRAlmcJimiTZKVRsk260
      # Tencent Cloud Region
      location: ap-guangzhou

depends:

  tencentcloud-sdk-python

salt.cloud.clouds.tencentcloud.avail_images(call=None)

  Return Tencent Cloud available image

  CLI Example:

      salt-cloud --list-images my-tencentcloud-config
      salt-cloud -f avail_images my-tencentcloud-config

salt.cloud.clouds.tencentcloud.avail_locations(call=None)

  Return Tencent Cloud available region

  CLI Example:

      salt-cloud --list-locations my-tencentcloud-config
      salt-cloud -f avail_locations my-tencentcloud-config

salt.cloud.clouds.tencentcloud.avail_sizes(call=None)

  Return Tencent Cloud available instance type

  CLI Example:

      salt-cloud --list-sizes my-tencentcloud-config
      salt-cloud -f avail_sizes my-tencentcloud-config

salt.cloud.clouds.tencentcloud.create(vm_)

  Create a single Tencent Cloud instance from a data dict.

  Tencent Cloud profiles require a `provider`, `availability_zone`, `image` and `size`. Set up profile at `/etc/salt/cloud.profiles` or `/etc/salt/cloud.profiles.d/*.conf`:

      tencentcloud-guangzhou-s1sm1:
          provider: my-tencentcloud-config
          availability_zone: ap-guangzhou-3
          image: img-31tjrtph
          size: S1.SMALL1
          allocate_public_ip: True
          internet_max_bandwidth_out: 1
          password: '153e41ec96140152'
          securitygroups:
              - sg-5e90804b

  CLI Examples:

      salt-cloud -p tencentcloud-guangzhou-s1 myinstance

salt.cloud.clouds.tencentcloud.destroy(name, call=None)

  Destroy a Tencent Cloud instance

  CLI Example:

      salt-cloud -a destroy myinstance
      salt-cloud -d myinstance

salt.cloud.clouds.tencentcloud.get_configured_provider()

  Return the first configured instance.

salt.cloud.clouds.tencentcloud.get_dependencies()

  Warn if dependencies aren't met.

salt.cloud.clouds.tencentcloud.get_provider_client(name=None)

  Return a new provider client

salt.cloud.clouds.tencentcloud.list_availability_zones(call=None)

  Return all Tencent Cloud availability zones in current region

  CLI Example:

      salt-cloud -f list_availability_zones my-tencentcloud-config

salt.cloud.clouds.tencentcloud.list_custom_images(call=None)

  Return all Tencent Cloud images in current region

  CLI Example:

      salt-cloud -f list_custom_images my-tencentcloud-config

salt.cloud.clouds.tencentcloud.list_nodes(call=None)

  Return a list of instances that are on the provider

  CLI Examples:

      salt-cloud -Q

salt.cloud.clouds.tencentcloud.list_nodes_full(call=None)

  Return a list of instances that are on the provider, with full details

  CLI Examples:

      salt-cloud -F

salt.cloud.clouds.tencentcloud.list_nodes_min(call=None)

  Return a list of instances that are on the provider, Only names, and their state, is returned.

  CLI Examples:

      salt-cloud -f list_nodes_min my-tencentcloud-config

salt.cloud.clouds.tencentcloud.list_nodes_select(call=None)

  Return a list of instances that are on the provider, with select fields

  CLI Examples:

      salt-cloud -S

salt.cloud.clouds.tencentcloud.list_securitygroups(call=None)

  Return all Tencent Cloud security groups in current region

  CLI Example:

      salt-cloud -f list_securitygroups my-tencentcloud-config

salt.cloud.clouds.tencentcloud.reboot(name, call=None)

  Reboot a Tencent Cloud instance

  CLI Examples:

      salt-cloud -a reboot myinstance

salt.cloud.clouds.tencentcloud.script(vm_)

  Return the script deployment object

salt.cloud.clouds.tencentcloud.show_disk(name, call=None)

  Show the disk details of Tencent Cloud instance

  CLI Examples:

      salt-cloud -a show_disk myinstance

salt.cloud.clouds.tencentcloud.show_image(kwargs, call=None)

  Show the details of Tencent Cloud image

  CLI Examples:

      salt-cloud -f show_image tencentcloud image=img-31tjrtph

salt.cloud.clouds.tencentcloud.show_instance(name, call=None)

  Show the details of Tencent Cloud instance

  CLI Examples:

      salt-cloud -a show_instance myinstance

salt.cloud.clouds.tencentcloud.start(name, call=None)

  Start a Tencent Cloud instance Notice: the instance state must be stopped

  CLI Examples:

      salt-cloud -a start myinstance

salt.cloud.clouds.tencentcloud.stop(name, force=False, call=None)

  Stop a Tencent Cloud running instance Note: use force=True to make force stop

  CLI Examples:

      salt-cloud -a stop myinstance
      salt-cloud -a stop myinstance force=True