Files
openstacksdk/doc/source/user/guides/compute.rst
Monty Taylor 40d425c595 Merge user and users sections of the docs
The openstack doc standard location is 'user', so go with that.
Incorporate pages from the shade and occ docs into the appropriate
places in the user index file.

This still leaves user/logging and user/guide/logging which need to be
rationalized. That will come in the next commit, as it also needs to
actually rationalize the logging helper functions.

Remove the Makefile, as it's not used by things.

Change-Id: I26f36370ef9651f4bcaa7dee3b903309463d9592
2018-01-15 19:19:50 -06:00

2.6 KiB
Raw Blame History

Using OpenStack Compute

Before working with the Compute service, you'll need to create a connection to your OpenStack cloud by following the connect user guide. This will provide you with the conn variable used in the examples below.

Table of Contents

The primary resource of the Compute service is the server.

List Servers

A server is a virtual machine that provides access to a compute instance being run by your cloud provider.

../examples/compute/list.py

Full example: compute resource list

List Images

An image is the operating system you want to use for your server.

../examples/compute/list.py

Full example: compute resource list

List Flavors

A flavor is the resource configuration for a server. Each flavor is a unique combination of disk, memory, vCPUs, and network bandwidth.

../examples/compute/list.py

Full example: compute resource list

List Networks

A network provides connectivity to servers.

../examples/network/list.py

Full example: network resource list

Create Key Pair

A key pair is the public key and private key of publickey cryptography. They are used to encrypt and decrypt login information when connecting to your server.

../examples/compute/create.py

Full example: compute resource create

Create Server

At minimum, a server requires a name, an image, a flavor, and a network on creation. You can discover the names and IDs of these attributes by listing them as above and then using the find methods to get the appropriate resources.

Ideally you'll also create a server using a keypair so you can login to that server with the private key.

Servers take time to boot so we call wait_for_server to wait for it to become active.

../examples/compute/create.py

Full example: compute resource create