diff --git a/contents/contents-user.rst b/contents/contents-user.rst index 340c91118..fddac7714 100644 --- a/contents/contents-user.rst +++ b/contents/contents-user.rst @@ -9,5 +9,6 @@ .. include:: /pages/user-guide/post-install-healthchecks.rst .. include:: /pages/user-guide/7000-sahara-install.rst .. include:: /pages/user-guide/8000-upgrade.rst +.. include:: /pages/user-guide/9000-role-operations.rst .. include:: /pages/user-guide/cli.rst .. include:: /pages/user-guide/vmware-integration-notes.rst diff --git a/pages/user-guide/9000-role-operations.rst b/pages/user-guide/9000-role-operations.rst new file mode 100644 index 000000000..c1fc846c2 --- /dev/null +++ b/pages/user-guide/9000-role-operations.rst @@ -0,0 +1,5 @@ + +Role operations +================ + +.. include :: /pages/user-guide/roles/0010-role.rst diff --git a/pages/user-guide/cli.rst b/pages/user-guide/cli.rst index 90b2653e7..474d96474 100644 --- a/pages/user-guide/cli.rst +++ b/pages/user-guide/cli.rst @@ -277,6 +277,74 @@ Assign nodes to the specified node group: fuel --env nodegroup --assign --node ,, --group +.. _roles-operations: + +Roles operations +++++++++++++++++ + +CLI basically implements standard CRUD for operating on a role. + +* List a role: + + :: + + fuel role --rel 2 + + name | id + --------------|--- + controller | 9 + compute | 10 + cinder | 11 + cinder-vmware | 12 + ceph-osd | 13 + mongo | 14 + zabbix-server | 15 + base-os | 16 + + +* Create a new role. + + - In this example, + we first create a swift role in ``swift.yaml``: + + :: + + meta: + description: Installs swift server. + has_primary: true # we need primary-swift and swift during orchestration + name: Swift + name: swift + volumes_roles_mapping: + - allocate_size: min + id: os + + - Then use ``--create`` flag to proceed. When created, + you can start using a new role for your own tasks: + + :: + + fuel role --rel <2> --create --file + + fuel role --rel <2> + + name | id + -------- + swift | 17 + + +* Update role data: + + :: + + fuel role --rel <2> --update --file + +* Delete the role: + + :: + + fuel role --rel <2> --delete --role + + .. _fuel-cli-config: Configuring diff --git a/pages/user-guide/roles/0010-role.rst b/pages/user-guide/roles/0010-role.rst new file mode 100644 index 000000000..37171c702 --- /dev/null +++ b/pages/user-guide/roles/0010-role.rst @@ -0,0 +1,64 @@ + +Role object +------------ + +Beginning with Fuel 6.1, +you can create, update or delete roles +using :ref:`Nailgun ` +REST API and Fuel Client. + +For Fuel CLI command reference, see +:ref:`Role operations ` +section. + +This section provides the Controller +role example: + +:: + + id: 9 + meta: + conflicts: + - compute + description: The controller initiates orchestration activities and provides an external + API. Other components like Glance (image storage), Keystone (identity management), + Horizon (OpenStack dashboard) and Nova-Scheduler are installed on the controller + as well. + has_primary: true + limits: + min: 1 + overrides: + - condition: cluster:mode == 'multinode' + max: 1 + message: Multi-node environment can not have more than one controller node. + - condition: cluster:mode == 'ha_compact' + message: At least 3 controller nodes are recommended for HA deployment. + recommended: 3 + name: Controller + update_required: + - compute + - cinder + name: controller + volumes_roles_mapping: + - allocate_size: min + id: os + - allocate_size: all + id: image + +The following fields are mandatory: + +:: + + name: controller + meta: + name: Controller + description: Description goes here + + # at least one volume is required + volumes_roles_mapping: + - allocate_size: min + id: os + +Primary behaviour for node can be enabled with ``has_primary: true`` option. +If this option is set to ``during orchestration``, you will be able to assign separate +tasks for primary-controller and controller.