diff --git a/doc/source/admin/magnum-proxy.rst b/doc/source/admin/magnum-proxy.rst index 7faa6281b2..9e0c5b0293 100644 --- a/doc/source/admin/magnum-proxy.rst +++ b/doc/source/admin/magnum-proxy.rst @@ -40,7 +40,7 @@ Steps to configure proxies. You can specify all three proxy parameters while creating ClusterTemplate of any coe type. All of proxy parameters are optional. - magnum cluster-template-create k8s-cluster-template \ + openstack coe cluster template create k8s-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -50,7 +50,7 @@ any coe type. All of proxy parameters are optional. --http-proxy \ --https-proxy \ --no-proxy <172.24.4.4,172.24.4.9,172.24.4.8> - magnum cluster-template-create swarm-cluster-template \ + openstack coe cluster template create swarm-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -60,7 +60,7 @@ any coe type. All of proxy parameters are optional. --http-proxy \ --https-proxy \ --no-proxy <172.24.4.4,172.24.4.9,172.24.4.8> - magnum cluster-template-create mesos-cluster-template \ + openstack coe cluster template create mesos-cluster-template \ --image ubuntu-mesos \ --keypair testkey \ --external-network public \ diff --git a/doc/source/contributor/quickstart.rst b/doc/source/contributor/quickstart.rst index b67d9bb0a0..c0fe231e04 100644 --- a/doc/source/contributor/quickstart.rst +++ b/doc/source/contributor/quickstart.rst @@ -215,12 +215,12 @@ when installing devstack use:: To list the available commands and resources for magnum, use:: - magnum help + openstack help coe To list out the health of the internal services, namely conductor, of magnum, use:: - $ magnum service-list + $ openstack coe service list +----+---------------------------------------+------------------+-------+----------+-----------------+---------------------------+---------------------------+ | id | host | binary | state | disabled | disabled_reason | created_at | updated_at | @@ -250,10 +250,9 @@ Building a Kubernetes Cluster - Based on Fedora Atomic Create a ClusterTemplate. This is similar in nature to a flavor and describes to magnum how to construct the cluster. The ClusterTemplate specifies a Fedora Atomic image so the clusters which use this ClusterTemplate will be based on -Fedora Atomic. The COE (Container Orchestration Engine) and keypair need to -be specified as well:: +Fedora Atomic:: - magnum cluster-template-create k8s-cluster-template \ + openstack coe cluster template create k8s-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -267,7 +266,7 @@ Create a cluster. Use the ClusterTemplate name as a template for cluster creation. This cluster will result in one master kubernetes node and one minion node:: - magnum cluster-create k8s-cluster \ + openstack coe cluster create k8s-cluster \ --cluster-template k8s-cluster-template \ --node-count 1 @@ -279,7 +278,7 @@ magnum to become confused. The existing clusters can be listed as follows:: - $ magnum cluster-list + $ openstack coe cluster list +--------------------------------------+-------------+------------+--------------+-----------------+ | uuid | name | node_count | master_count | status | @@ -289,13 +288,13 @@ The existing clusters can be listed as follows:: More detailed information for a given cluster is obtained via:: - magnum cluster-show k8s-cluster + openstack coe cluster show k8s-cluster After a cluster is created, you can dynamically add/remove node(s) to/from the cluster by updating the node_count attribute. For example, to add one more node:: - magnum cluster-update k8s-cluster replace node_count=2 + openstack coe cluster update k8s-cluster replace node_count=2 Clusters in the process of updating will have a status of UPDATE_IN_PROGRESS. Magnum will update the status to UPDATE_COMPLETE when it is done updating @@ -349,7 +348,7 @@ Upload the image to glance:: Create a CoreOS Kubernetes ClusterTemplate, which is similar to the Atomic Kubernetes ClusterTemplate, except for pointing to a different image:: - magnum cluster-template-create k8s-cluster-template-coreos \ + openstack coe cluster template create k8s-cluster-template-coreos \ --image CoreOS \ --keypair testkey \ --external-network public \ @@ -361,7 +360,7 @@ Kubernetes ClusterTemplate, except for pointing to a different image:: Create a CoreOS Kubernetes cluster. Use the CoreOS ClusterTemplate as a template for cluster creation:: - magnum cluster-create k8s-cluster \ + openstack coe cluster create k8s-cluster \ --cluster-template k8s-cluster-template-coreos \ --node-count 2 @@ -421,7 +420,7 @@ Here's how to set up the replicated redis example. Now we create a pod for the redis-master:: # Using cluster-config command for faster configuration - eval $(magnum cluster-config k8s-cluster) + eval $(openstack coe cluster config k8s-cluster) # Test the cert and connection works kubectl version @@ -444,15 +443,16 @@ redis slaves and sentinels:: kubectl create -f ./redis-sentinel-controller.yaml Full lifecycle and introspection operations for each object are supported. -For example, magnum cluster-create, magnum cluster-template-delete. +For example, openstack coe cluster create, openstack coe cluster template +delete. Now there are four redis instances (one master and three slaves) running across the cluster, replicating data between one another. -Run the cluster-show command to get the IP of the cluster host on which the -redis-master is running:: +Run the openstack coe cluster show command to get the IP of the cluster host on +which the redis-master is running:: - $ magnum cluster-show k8s-cluster + $ openstack coe cluster show k8s-cluster +--------------------+------------------------------------------------------------+ | Property | Value | @@ -514,7 +514,7 @@ Additional useful commands from a given minion:: After you finish using the cluster, you want to delete it. A cluster can be deleted as follows:: - magnum cluster-delete k8s-cluster + openstack coe cluster delete k8s-cluster Building and Using a Swarm Cluster ================================== @@ -523,7 +523,7 @@ Create a ClusterTemplate. It is very similar to the Kubernetes ClusterTemplate, except for the absence of some Kubernetes-specific arguments and the use of 'swarm' as the COE:: - magnum cluster-template-create swarm-cluster-template \ + openstack coe cluster template create swarm-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -539,13 +539,13 @@ Finally, create the cluster. Use the ClusterTemplate 'swarm-cluster-template' as a template for cluster creation. This cluster will result in one swarm manager node and two extra agent nodes:: - magnum cluster-create swarm-cluster \ + openstack coe cluster create swarm-cluster \ --cluster-template swarm-cluster-template \ --node-count 2 Now that we have a swarm cluster we can start interacting with it:: - $ magnum cluster-show swarm-cluster + $ openstack coe cluster show swarm-cluster +--------------------+------------------------------------------------------------+ | Property | Value | @@ -617,7 +617,7 @@ Set the CLI to use TLS . This env var is consumed by docker.:: Set the correct host to use which is the public ip address of swarm API server endpoint. This env var is consumed by docker.:: - export DOCKER_HOST=$(magnum cluster-show swarm-cluster | awk '/ api_address /{print substr($4,7)}') + export DOCKER_HOST=$(openstack coe cluster show swarm-cluster | awk '/ api_address /{print substr($4,7)}') Next we will create a container in this swarm cluster. This container will ping the address 8.8.8.8 four times:: @@ -653,7 +653,7 @@ Alternatively, you can download and upload a pre-built image:: Then, create a ClusterTemplate by using 'mesos' as the COE, with the rest of arguments similar to the Kubernetes ClusterTemplate:: - magnum cluster-template-create mesos-cluster-template --image ubuntu-mesos \ + openstack coe cluster template create mesos-cluster-template --image ubuntu-mesos \ --keypair testkey \ --external-network public \ --dns-nameserver 8.8.8.8 \ @@ -664,14 +664,14 @@ Finally, create the cluster. Use the ClusterTemplate 'mesos-cluster-template' as a template for cluster creation. This cluster will result in one mesos master node and two mesos slave nodes:: - magnum cluster-create mesos-cluster \ + openstack coe cluster create mesos-cluster \ --cluster-template mesos-cluster-template \ --node-count 2 Now that we have a mesos cluster we can start interacting with it. First we need to make sure the cluster's status is 'CREATE_COMPLETE':: - $ magnum cluster-show mesos-cluster + $ openstack coe cluster show mesos-cluster +--------------------+------------------------------------------------------------+ | Property | Value | @@ -714,7 +714,7 @@ Marathon. This container will ping the address 8.8.8.8:: "cmd": "ping 8.8.8.8" } END - $ MASTER_IP=$(magnum cluster-show mesos-cluster | awk '/ api_address /{print $4}') + $ MASTER_IP=$(openstack coe cluster show mesos-cluster | awk '/ api_address /{print $4}') $ curl -X POST -H "Content-Type: application/json" \ http://${MASTER_IP}:8080/v2/apps -d@mesos.json diff --git a/doc/source/install/launch-instance.rst b/doc/source/install/launch-instance.rst index 9bc8e965ba..c585755164 100644 --- a/doc/source/install/launch-instance.rst +++ b/doc/source/install/launch-instance.rst @@ -168,7 +168,7 @@ container. .. code-block:: console - $ magnum cluster-template-create swarm-cluster-template \ + $ openstack coe cluster template create swarm-cluster-template \ --image fedora-atomic-latest \ --external-network public \ --dns-nameserver 8.8.8.8 \ @@ -215,7 +215,7 @@ container. .. code-block:: console - $ magnum cluster-create swarm-cluster \ + $ openstack coe cluster create swarm-cluster \ --cluster-template swarm-cluster-template \ --master-count 1 \ --node-count 1 \ @@ -224,12 +224,12 @@ container. Your cluster is now being created. Creation time depends on your infrastructure's performance. You can check the status of your cluster - using the commands: ``magnum cluster-list`` or - ``magnum cluster-show swarm-cluster``. + using the commands: ``openstack coe cluster list`` or + ``openstack coe cluster show swarm-cluster``. .. code-block:: console - $ magnum cluster-list + $ openstack coe cluster list +--------------------------------------+---------------+---------+------------+--------------+-----------------+ | uuid | name | keypair | node_count | master_count | status | +--------------------------------------+---------------+---------+------------+--------------+-----------------+ @@ -238,7 +238,7 @@ container. .. code-block:: console - $ magnum cluster-show swarm-cluster + $ openstack coe cluster show swarm-cluster +---------------------+------------------------------------------------------------+ | Property | Value | +---------------------+------------------------------------------------------------+ @@ -266,7 +266,7 @@ container. .. code-block:: console $ mkdir myclusterconfig - $ $(magnum cluster-config swarm-cluster --dir myclusterconfig) + $ $(openstack coe cluster config swarm-cluster --dir myclusterconfig) The above command will save the authentication artifacts in the @@ -291,7 +291,7 @@ container. .. code-block:: console - $ magnum cluster-delete swarm-cluster + $ openstack coe cluster delete swarm-cluster Request to delete cluster swarm-cluster has been accepted. Provision a Kubernetes cluster and create a deployment @@ -308,7 +308,7 @@ will create a deployment. .. code-block:: console - $ magnum cluster-template-create kubernetes-cluster-template \ + $ openstack coe cluster template create kubernetes-cluster-template \ --image fedora-atomic-latest \ --external-network public \ --dns-nameserver 8.8.8.8 \ @@ -355,7 +355,7 @@ will create a deployment. .. code-block:: console - $ magnum cluster-create kubernetes-cluster \ + $ openstack coe cluster create kubernetes-cluster \ --cluster-template kubernetes-cluster-template \ --master-count 1 \ --node-count 1 \ @@ -364,12 +364,12 @@ will create a deployment. Your cluster is now being created. Creation time depends on your infrastructure's performance. You can check the status of your cluster - using the commands: ``magnum cluster-list`` or - ``magnum cluster-show kubernetes-cluster``. + using the commands: ``openstack coe cluster list`` or + ``openstack coe cluster show kubernetes-cluster``. .. code-block:: console - $ magnum cluster-list + $ openstack coe cluster list +--------------------------------------+--------------------+---------+------------+--------------+-----------------+ | uuid | name | keypair | node_count | master_count | status | +--------------------------------------+--------------------+---------+------------+--------------+-----------------+ @@ -378,7 +378,7 @@ will create a deployment. .. code-block:: console - $ magnum cluster-show kubernetes-cluster + $ openstack coe cluster show kubernetes-cluster +---------------------+------------------------------------------------------------+ | Property | Value | +---------------------+------------------------------------------------------------+ @@ -407,7 +407,7 @@ will create a deployment. .. code-block:: console $ mkdir -p ~/clusters/kubernetes-cluster - $ $(magnum cluster-config kubernetes-cluster --dir ~/clusters/kubernetes-cluster) + $ $(openstack coe cluster config kubernetes-cluster --dir ~/clusters/kubernetes-cluster) The above command will save the authentication artifacts in the directory @@ -449,5 +449,5 @@ will create a deployment. .. code-block:: console - $ magnum cluster-delete kubernetes-cluster + $ openstack coe cluster delete kubernetes-cluster Request to delete cluster kubernetes-cluster has been accepted. diff --git a/doc/source/install/verify.rst b/doc/source/install/verify.rst index e39a6c73cf..cf90144946 100644 --- a/doc/source/install/verify.rst +++ b/doc/source/install/verify.rst @@ -20,7 +20,7 @@ Verify operation of the Container Infrastructure Management service. .. code-block:: console - $ magnum service-list + $ openstack coe service list +----+-----------------------+------------------+-------+ | id | host | binary | state | +----+-----------------------+------------------+-------+ diff --git a/doc/source/user/index.rst b/doc/source/user/index.rst index 68e1b2f3d6..df83500772 100644 --- a/doc/source/user/index.rst +++ b/doc/source/user/index.rst @@ -442,7 +442,7 @@ is used as the baymodel parameter for this command instead of The 'cluster-create' command deploys a cluster, for example:: - magnum cluster-create mycluster \ + openstack coe cluster create mycluster \ --cluster-template mytemplate \ --node-count 8 \ --master-count 3 @@ -515,7 +515,7 @@ List The 'cluster-list' command lists all the clusters that belong to the tenant, for example:: - magnum cluster-list + openstack coe cluster list Show ++++ @@ -523,7 +523,7 @@ Show The 'cluster-show' command prints all the details of a cluster, for example:: - magnum cluster-show mycluster + openstack coe cluster show mycluster The properties include those not specified by users that have been assigned default values and properties from new resources that @@ -534,7 +534,7 @@ Update A cluster can be modified using the 'cluster-update' command, for example:: - magnum cluster-update mycluster replace node_count=8 + openstack coe cluster update mycluster replace node_count=8 The parameters are positional and their definition and usage are as follows. @@ -585,7 +585,7 @@ Scaling a cluster means adding servers to or removing servers from the cluster. Currently, this is done through the 'cluster-update' operation by modifying the node-count attribute, for example:: - magnum cluster-update mycluster replace node_count=2 + openstack coe cluster update mycluster replace node_count=2 When some nodes are removed, Magnum will attempt to find nodes with no containers to remove. If some nodes with containers must be removed, @@ -597,7 +597,7 @@ Delete The 'cluster-delete' operation removes the cluster by deleting all resources such as servers, network, storage; for example:: - magnum cluster-delete mycluster + openstack coe cluster delete mycluster The only parameter for the cluster-delete command is the ID or name of the cluster to delete. Multiple clusters can be specified, separated by a blank @@ -643,21 +643,18 @@ Install using distribution packages for OpenSuSE and SuSE Enterprise Linux:: Verifying installation ---------------------- -Execute the `magnum` command with the `--version` argument to confirm that the -client is installed and in the system path:: +Execute the `openstack help coe` command to confirm that the client is +installed and in the system path:: - $ magnum --version + $ openstack help coe 1.1.0 -Note that the version returned may differ from the above, 1.1.0 was the latest -available version at the time of writing. - Using the command-line client ----------------------------- Refer to the `OpenStack Command-Line Interface Reference `_ for a full list of the -commands supported by the `magnum` command-line client. +commands supported by the `openstack coe` command-line client. Horizon Interface ================= @@ -896,7 +893,7 @@ follows:: Kubernetes also provides a browser UI. If the cluster has the Kubernetes Dashboard running; it can be accessed using:: - eval $(magnum cluster-config ) + eval $(openstack coe cluster config ) kubectl proxy The browser can be accessed at http://localhost:8001/ui @@ -914,7 +911,7 @@ the client that matches the version in the cluster. To determine the version of the COE and container, use the command 'cluster-show' and look for the attribute *coe_version* and *container_version*:: - magnum cluster-show k8s-cluster + openstack coe cluster show k8s-cluster +--------------------+------------------------------------------------------------+ | Property | Value | +--------------------+------------------------------------------------------------+ @@ -976,7 +973,7 @@ Service When Magnum deploys a Kubernetes cluster, it uses parameters defined in the ClusterTemplate and specified on the cluster-create command, for example:: - magnum cluster-template-create k8s-cluster-template \ + openstack coe cluster template create k8s-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -986,7 +983,7 @@ ClusterTemplate and specified on the cluster-create command, for example:: --network-driver flannel \ --coe kubernetes - magnum cluster-create k8s-cluster \ + openstack coe cluster create k8s-cluster \ --cluster-template k8s-cluster-template \ --master-count 3 \ --node-count 8 @@ -1134,7 +1131,7 @@ Magnum deploys a Swarm cluster using parameters defined in the ClusterTemplate and specified on the 'cluster-create' command, for example:: - magnum cluster-template-create swarm-cluster-template \ + openstack coe cluster template create swarm-cluster-template \ --image fedora-atomic-latest \ --keypair testkey \ --external-network public \ @@ -1143,7 +1140,7 @@ example:: --docker-volume-size 5 \ --coe swarm - magnum cluster-create swarm-cluster \ + openstack coe cluster create swarm-cluster \ --cluster-template swarm-cluster-template \ --master-count 3 \ --node-count 8 @@ -1254,7 +1251,7 @@ offered. Magnum deploys a Mesos cluster using parameters defined in the ClusterTemplate and specified on the 'cluster-create' command, for example:: - magnum cluster-template-create mesos-cluster-template \ + openstack coe cluster template create mesos-cluster-template \ --image ubuntu-mesos \ --keypair testkey \ --external-network public \ @@ -1262,7 +1259,7 @@ and specified on the 'cluster-create' command, for example:: --flavor m1.small \ --coe mesos - magnum cluster-create mesos-cluster \ + openstack coe cluster create mesos-cluster \ --cluster-template mesos-cluster-template \ --master-count 3 \ --node-count 8 @@ -1504,7 +1501,7 @@ For example, you can 'post' a JSON app description to "cmd": "while sleep 10; do date -u +%T; done" } END - $ API_ADDRESS=$(magnum cluster-show mesos-cluster | awk '/ api_address /{print $4}') + $ API_ADDRESS=$(openstack coe cluster show mesos-cluster | awk '/ api_address /{print $4}') $ curl -X POST -H "Content-Type: application/json" \ http://${API_ADDRESS}:8080/v2/apps -d@app.json @@ -1563,7 +1560,7 @@ support. First, create a ClusterTemplate; by default TLS is enabled in Magnum, therefore it does not need to be specified via a parameter:: - magnum cluster-template-create secure-kubernetes \ + openstack coe cluster template create secure-kubernetes \ --keypair default \ --external-network public \ --image fedora-atomic-latest \ @@ -1609,7 +1606,7 @@ Magnum, therefore it does not need to be specified via a parameter:: Now create a cluster. Use the ClusterTemplate name as a template for cluster creation:: - magnum cluster-create secure-k8s-cluster \ + openstack coe cluster create secure-k8s-cluster \ --cluster-template secure-kubernetes \ --node-count 1 @@ -1639,7 +1636,7 @@ creation:: Now run cluster-show command to get the details of the cluster and verify that the api_address is 'https':: - magnum cluster-show secure-k8scluster + openstack coe cluster show secure-k8scluster +--------------------+------------------------------------------------------------+ | Property | Value | +--------------------+------------------------------------------------------------+ @@ -1686,7 +1683,7 @@ Automated Magnum provides the command 'cluster-config' to help the user in setting up the environment and artifacts for TLS, for example:: - magnum cluster-config swarm-cluster --dir myclusterconfig + openstack coe cluster config swarm-cluster --dir myclusterconfig This will display the necessary environment variables, which you can add to your environment:: @@ -1780,7 +1777,7 @@ User Examples Here are some examples for using the CLI on a secure Kubernetes and Swarm cluster. You can perform all the TLS set up automatically by:: - eval $(magnum cluster-config ) + eval $(openstack coe cluster config ) Or you can perform the manual steps as described above and specify the TLS options on the CLI. The SSL artifacts are assumed to be @@ -1809,7 +1806,7 @@ in the environment:: You can specify the TLS options manually as follows:: - KUBERNETES_URL=$(magnum cluster-show secure-k8s-cluster | + KUBERNETES_URL=$(openstack coe cluster show secure-k8s-cluster | awk '/ api_address /{print $4}') kubectl version --certificate-authority=ca.pem \ --client-key=key.pem \ @@ -2113,7 +2110,7 @@ supports manual scaling through the attribute 'node_count' in the cluster, so you can scale the cluster simply by changing this attribute:: - magnum cluster-update mycluster replace node_count=2 + openstack coe cluster update mycluster replace node_count=2 Refer to the section `Scale`_ lifecycle operation for more details. @@ -2286,7 +2283,7 @@ The public Fedora image from Atomic currently meets this requirement. Specify 'cinder' as the volume-driver for Kubernetes:: - magnum cluster-template-create k8s-cluster-template \ + openstack coe cluster template create k8s-cluster-template \ --image fedora-23-atomic-7 \ --keypair testkey \ --external-network public \ @@ -2299,7 +2296,7 @@ The public Fedora image from Atomic currently meets this requirement. 2. Create the cluster:: - magnum cluster-create k8s-cluster \ + openstack coe cluster create k8s-cluster \ --cluster-template k8s-cluster-template \ --node-count 1 @@ -2378,7 +2375,7 @@ Using Cinder in Mesos hosts are using the volume. If this is set to false, the driver will ensure data safety by locking the volume:: - magnum cluster-template-create mesos-cluster-template \ + openstack coe cluster template create mesos-cluster-template \ --image ubuntu-mesos \ --keypair testkey \ --external-network public \ @@ -2393,7 +2390,7 @@ Using Cinder in Mesos 2. Create the Mesos cluster:: - magnum cluster-create mesos-cluster \ + openstack coe cluster create mesos-cluster \ --cluster-template mesos-cluster-template \ --node-count 1 @@ -2437,7 +2434,7 @@ the cinder volume in the JSON file :: 4. Create the container using Marathon REST API :: - MASTER_IP=$(magnum cluster-show mesos-cluster | awk '/ api_address /{print $4}') + MASTER_IP=$(openstack coe cluster show mesos-cluster | awk '/ api_address /{print $4}') curl -X POST -H "Content-Type: application/json" \ http://${MASTER_IP}:8080/v2/apps -d@mesos.json