Skip to content

ChameleonCloud/python-doniclient

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

112 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ChameleonCloud Python Doniclient CLI

ChameleonCloud Logo

Welcome to the ChameleonCloud Python Doniclient CLI repository! This command-line interface (CLI) provides a convenient way to interact with ChameleonCloud's Doni hardware inventory project, enabling you to manage and automate various hardware-related tasks.

Table of Contents

Installation

You can install the ChameleonCloud Python Doniclient CLI using pip:

pip install python-doniclient

Cython sources issue

if you encounter an error message citing cython sources, please run the following to downgrade cython to a compatible version and use PyYaml 6.0+ pip install "cython<3.0.0"

Authentication

Environment variables are the primary authentication method. Please refer to the documentation on OpenRC scripts to learn more about how to download and source your authentication credentials for the CLI;

Usage

To use the CLI, you can run the openstack hardware command followed by the desired subcommand. openstack hardware --help shows all the subcommands available. Here's a basic usage examples:

List all hardware in the Doni database.

openstack hardware list

Options:

  • --all: List hardware from all owners (requires admin rights).
  • --long: Include all columns in the output.
  • --worker-type <worker_type>: Filter by worker type.
  • --worker-state <worker_state>: Filter by worker state (choices: PENDING, IN_PROGRESS, ERROR, STEADY).

For more details on specific commands and their options use --help or -h

Create hardware in the Doni database

openstack hardware create --name <hardware_name> --hardware-type <hardware_type> --property <property_name>=<property_value>

List specific hardware item in Doni using name or uuid.

openstack hardware get <hardware_uuid>
openstack hardware get <hardware_name>

Set properties and name of an existing hardware item.

openstack hardware set <hardware_uuid> --name <new_hardware_name> --property <property_name>=<new_property_value>

Sets new name and property for the item <hardware_uuid>

openstack hardware set <hardware_name> --property <property_name>=<new_property_value>

Sets property for the item <hardware_name

Unset properties of an existing hardware item.

openstack hardware unset <hardware_uuid> --property <property_name>

Unsets property <property_name> for the item <hardware_uuid

openstack hardware update <hardware_name> --property <property_name>=<new_property_value>

Unsets property <property_name> for the item <hardware_name>

About

Client for Chameleon Registration Service

Resources

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages