The docker-ostk utility is designed to be used on a master node, but it can be used on any Oracle Linux 6 or 7 host. Because docker-ostk runs the OpenStack command-line clients in a Docker container, the Docker Engine must be installed on the host. For details of the required Yum repositories and Docker configuration, see:
Section 3.5, “Preparing Oracle Linux Nodes” (Oracle Linux 7)
Section 3.6, “Preparing Oracle VM Server Nodes” (Oracle Linux 6)
To install the docker-ostk utility:
# yum install openstack-kolla-utils
In order to run Docker containers, the user that runs the
docker-ostk utility must be a member of the
docker
group. To add an existing user to the
docker
group:
# usermod -aG docker username
The user must log out and in again for the group setting to take effect.
Any member of the docker
group has full
(root) access to all Docker containers on a host. If you add an
unprivileged user to the docker
group, you
should consider the elevation in security granted with this
access. Do not run the docker-ostk
utility as
the root user.
When you use docker-ostk utility, it pulls
(downloads) the ol-openstack-kolla-toolbox
Docker image from a Docker registry.
If you use docker-ostk on a master node, the
Docker registry defined by the
docker_registry
property is used. By default,
this property is set to the Oracle Container Registry, see
Section 4.3, “Setting up the Docker Registry”.
If you use docker-ostk on a host that is not
a master node, or you want to use a different registry than the
one defined by by the docker_registry
property, you must set the OPENSTACK_UTILS_IMAGE
environment variable with the full location of the Docker image
using the form:
registry_hostname
:port
/namespace
/ol-openstack-kolla-toolbox:release_tag
For example, to use the image in the Oracle Container Registry:
$ export \ OPENSTACK_UTILS_IMAGE=container-registry.oracle.com/openstack/ol-openstack-kolla-toolbox:3.0.1
If you are using the Oracle Container Registry, you might need to sign in at https://container-registry.oracle.com and accept the Oracle Standard Terms and Restrictions for the Oracle software images before using the docker-ostk utility for the first time. After you accept the terms, you also need to register your login credentials for the Oracle Container Registry with Docker so that you can pull (download) images:
$ docker login -u user-name
container-registry-stage.oracle.com
Password:
Login Succeeded
Before you use OpenStack CLI clients, you usually need to set OpenStack environment variables to enable you to authenticate to Keystone. See Section 7.3, “Setting Environment Variables for OpenStack CLI Clients” for details. When you use the docker-ostk utility, it creates a temporary file in the current working directory containing your OpenStack environment variables. The temporary file is used to pass the environment variables to the Docker container and is deleted when you stop using the docker-ostk utility. You must have write permission for the current working directory in order to create the temporary file.
To use the docker-ostk utility, use the syntax:
$ docker-ostkopenstack_client
openstack_client_argument
[ -h | --help ]
-
openstack_client
An OpenStack CLI client, for example,
openstack
ornova
.-
openstack_client_argument
The argument for the OpenStack CLI client command, for example,
list
.-
-h
,--help
Display syntax help.
For example:
$ docker-ostk nova list
To access files on a local file system from a container, the
docker-ostk utility bind-mounts the current
working directory on the host into the Docker container at
/data
. To use local files, you must have read
permission for the current working directory and the files used
in the command. For example, to create a Glance image using the
cirros-0.3.4-x86_64-disk.img
file in the
current working directory:
$ docker-ostk glance image-create --name cirros --is-public True --disk-format qcow2 \ --container-format bare --file cirros-0.3.4-x86_64-disk.img
For information about OpenStack CLI clients, see http://docs.openstack.org/cli-reference/index.html.