Group configuration

The Configuration API is used to configure the group configuration. All nodes part of the group will by default inherit the configuration set for the group.

Get a list of groups (GET /config/group)

Request

GET /config/group

Example:

GET  https://controller1.cluster:7050/config/group
Parameter Description
None -

Request header

x-access-tokens: "<TOKEN>"

Request body

Query parameters

Parameter Presence Type Description
None - - -

Response body

All the groups are returned.

{
  "config": {
    "group": {
      "compute": {
        "name": "compute",
        "setupbmc": true,
        "domain": "cluster",
        "osimagetagid": null,
        "prescript": null,
        "partscript": "bW91bnQgLXQgdG1wZnMgdG1wZnMgL3N5c3Jvb3QK",
        "postscript": "ZWNobyAndG1wZnMgLyB0bXBmcyBkZWZhdWx0cyAwIDAnID4+IC9zeXNyb290L2V0Yy9mc3RhYgo=",
        "netboot": true,
        "localinstall": false,
        "bootmenu": false,
        "comment": null,
        "roles": null,
        "provision_interface": null,
        "provision_method": null,
        "provision_fallback": null,
        "unmanaged_bmc_users": null,
        "interfaces": [
          {
            "interface": "BOOTIF",
            "network": "cluster",
            "options": ""
          },
          {
            "interface": "BMC",
            "network": "ipmi",
            "options": ""
          }
        ],
        "osimage": "compute",
        "bmcsetupname": "compute"
      },
      "gpu": {
        "name": "gpu",
        "setupbmc": false,
        "domain": null,
        "osimagetagid": null,
        "prescript": "",
        "partscript": "",
        "postscript": "",
        "netboot": false,
        "localinstall": false,
        "bootmenu": false,
        "comment": null,
        "roles": null,
        "provision_interface": "BOOTIF",
        "provision_method": null,
        "provision_fallback": null,
        "unmanaged_bmc_users": null,
        "osimage": null
      }      
    }
  }
}

Response header

State Code Description
OK 200 OK Indicates the request has succeeded
FAIL HTTP 401 Unauthorized Mandatory if the credentials are invalid
FAIL HTTP 503 Service unavailable This is returned when the backend is unavailable.

Get group information (GET /config/group/<string:groupname>)

To select only one group, specify the groupname. If the group does not exist, a 404 will be returned.

Request

GET /config/group/<string:groupname>

Example:

GET  https://controller1.cluster:7050/config/group/compute
Parameter Description
groupname Groupname as configured in Luna.

Request header

x-access-tokens: "<TOKEN>"

Request body

Query parameters

Parameter Presence Type Description
None - - -

Response body

{
  "config": {
    "group": {
      "compute": {
        "name": "compute",
        "setupbmc": true,
        "domain": "cluster",
        "osimagetagid": null,
        "prescript": null,
        "partscript": "bW91bnQgLXQgdG1wZnMgdG1wZnMgL3N5c3Jvb3QK",
        "postscript": "ZWNobyAndG1wZnMgLyB0bXBmcyBkZWZhdWx0cyAwIDAnID4+IC9zeXNyb290L2V0Yy9mc3RhYgo=",
        "netboot": true,
        "localinstall": false,
        "bootmenu": false,
        "comment": null,
        "roles": null,
        "provision_interface": null,
        "provision_method": null,
        "provision_fallback": null,
        "unmanaged_bmc_users": null,
        "interfaces": [
          {
            "interface": "BOOTIF",
            "network": "cluster",
            "options": ""
          },
          {
            "interface": "BMC",
            "network": "ipmi",
            "options": ""
          }
        ],
        "osimage": "compute",
        "bmcsetupname": "compute"
      }
    }
  }
}

Response header

State Code Description
OK 200 OK Indicates the request has succeeded
FAIL HTTP 401 Unauthorized Mandatory if the credentials are invalid
FAIL HTTP 503 Service unavailable This is returned when the backend is unavailable.
FAIL 404 Not Found The server can not find the resource

Get a list members of the groups (GET /config/group/<string:groupname>/_list)

Create, update and rename group information (POST /config/group/<string:groupname>)

Clone a group (POST /config/group/<string:groupname>/_clone)

Deleting a group (GET /config/group/<string:groupname>/_delete)

Get group interface information (GET /config/group/<string:groupname>/interfaces)

Create or update group interface information (POST /config/group/<string:groupname>/interfaces)

Retrieve group interface information (GET /config/group/<string:groupname>/interfaces/{interface})

Delete group interface (GET /config/group/<string:groupname>/interfaces/{interface}/_delete)