zhmcclient


Namezhmcclient JSON
Version 1.14.0 PyPI version JSON
download
home_pagehttps://github.com/zhmcclient/python-zhmcclient
SummaryA pure Python client library for the IBM Z HMC Web Services API.
upload_time2024-02-17 12:09:35
maintainerAndreas Maier, Kathir Velusamy
docs_urlNone
authorJuergen Leopold, Andreas Maier
requires_python>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*
licenseApache License, Version 2.0
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage
            .. Copyright 2016,2021 IBM Corp. All Rights Reserved.
..
.. Licensed under the Apache License, Version 2.0 (the "License");
.. you may not use this file except in compliance with the License.
.. You may obtain a copy of the License at
..
..    http://www.apache.org/licenses/LICENSE-2.0
..
.. Unless required by applicable law or agreed to in writing, software
.. distributed under the License is distributed on an "AS IS" BASIS,
.. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
.. See the License for the specific language governing permissions and
.. limitations under the License.
..

zhmcclient - A pure Python client library for the IBM Z HMC Web Services API
============================================================================

.. PyPI download statistics are broken, but the new PyPI warehouse makes PyPI
.. download statistics available through Google BigQuery
.. (https://bigquery.cloud.google.com).
.. Query to list package downloads by version:
..
   SELECT
     file.project,
     file.version,
     COUNT(*) as total_downloads,
     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r"^([^\.]+\.[^\.]+)") = "2.6" THEN 1 ELSE 0 END) as py26_downloads,
     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r"^([^\.]+\.[^\.]+)") = "2.7" THEN 1 ELSE 0 END) as py27_downloads,
     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r"^([^\.]+)\.[^\.]+") = "3" THEN 1 ELSE 0 END) as py3_downloads,
   FROM
     TABLE_DATE_RANGE(
       [the-psf:pypi.downloads],
       TIMESTAMP("19700101"),
       CURRENT_TIMESTAMP()
     )
   WHERE
     file.project = 'zhmcclient'
   GROUP BY
     file.project, file.version
   ORDER BY
     file.version DESC

.. image:: https://img.shields.io/pypi/v/zhmcclient.svg
    :target: https://pypi.python.org/pypi/zhmcclient/
    :alt: Version on Pypi

.. # .. image:: https://img.shields.io/pypi/dm/zhmcclient.svg
.. #     :target: https://pypi.python.org/pypi/zhmcclient/
.. #     :alt: Pypi downloads

.. image:: https://github.com/zhmcclient/python-zhmcclient/actions/workflows/test.yml/badge.svg?branch=master
    :target: https://github.com/zhmcclient/python-zhmcclient/actions/workflows/test.yml?query=branch%3Amaster
    :alt: Test status (master)

.. image:: https://readthedocs.org/projects/python-zhmcclient/badge/?version=latest
    :target: https://readthedocs.org/projects/python-zhmcclient/builds/
    :alt: Docs status (master)

.. image:: https://coveralls.io/repos/github/zhmcclient/python-zhmcclient/badge.svg?branch=master
    :target: https://coveralls.io/github/zhmcclient/python-zhmcclient?branch=master
    :alt: Test coverage (master)

.. image:: https://codeclimate.com/github/zhmcclient/python-zhmcclient/badges/gpa.svg
    :target: https://codeclimate.com/github/zhmcclient/python-zhmcclient
    :alt: CodeClimate status

.. contents:: Contents:
   :local:

Overview
========

The zhmcclient package is a client library
written in pure Python that interacts with the Web Services API of the Hardware
Management Console (HMC) of `IBM Z`_ or `LinuxONE`_ machines. The goal of
this package is to make the HMC Web Services API easily consumable for Python
programmers.

.. _IBM Z: http://www.ibm.com/systems/z/
.. _LinuxONE: http://www.ibm.com/systems/linuxone/

The HMC Web Services API is the access point for any external tools to
manage the IBM Z  or LinuxONE platform. It supports management of the
lifecycle and configuration of various platform resources, such as partitions,
CPU, memory, virtual switches, I/O adapters, and more.

The zhmcclient package encapsulates both protocols supported by the HMC Web
Services API:

* REST over HTTPS for request/response-style operations driven by the client.
  Most of these operations complete synchronously, but some long-running tasks
  complete asynchronously.

* JMS (Java Messaging Services) for notifications from the HMC to the client.
  This can be used to be notified about changes in the system, or about
  completion of asynchronous tasks started using REST.

Installation
============

The quick way:

.. code-block:: bash

    $ pip install zhmcclient

For more details, see the `Installation section`_ in the documentation.

.. _Installation section: http://python-zhmcclient.readthedocs.io/en/latest/intro.html#installation

Quickstart
===========

The following example code lists the partitions on CPCs in DPM mode that are
accessible for the user:

.. code-block:: python

    #!/usr/bin/env python

    import zhmcclient
    import requests.packages.urllib3
    requests.packages.urllib3.disable_warnings()

    # Set these variables for your environment:
    host = "<IP address or hostname of the HMC>"
    userid = "<userid on that HMC>"
    password = "<password of that HMC userid>"
    verify_cert = False

    session = zhmcclient.Session(host, userid, password, verify_cert=verify_cert)
    client = zhmcclient.Client(session)
    console = client.consoles.console

    partitions = console.list_permitted_partitions()
    for part in partitions:
        cpc = part.manager.parent
        print("{} {}".format(cpc.name, part.name))

Possible output when running the script:

.. code-block:: text

    P000S67B PART1
    P000S67B PART2
    P0000M96 PART1

Documentation and Change Log
============================

For the latest released version on PyPI:

* `Documentation`_
* `Change log`_

.. _Documentation: http://python-zhmcclient.readthedocs.io/en/latest/
.. _Change log: http://python-zhmcclient.readthedocs.io/en/latest/changes.html

zhmc CLI
========

Before version 0.18.0 of the zhmcclient package, it contained the zhmc CLI.
Starting with zhmcclient version 0.18.0, the zhmc CLI has been moved from this
project into the new `zhmccli project`_.

If your project uses the zhmc CLI, and you are upgrading the zhmcclient
package from before 0.18.0 to 0.18.0 or later, your project will need to add
the `zhmccli package`_ to its dependencies.

.. _zhmccli project: https://github.com/zhmcclient/zhmccli

.. _zhmccli package: https://pypi.python.org/pypi/zhmccli


Contributing
============

For information on how to contribute to this project, see the
`Development section`_ in the documentation.

.. _Development section: http://python-zhmcclient.readthedocs.io/en/latest/development.html

License
=======

The zhmcclient package is licensed under the `Apache 2.0 License`_.

.. _Apache 2.0 License: https://github.com/zhmcclient/python-zhmcclient/tree/master/LICENSE

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/zhmcclient/python-zhmcclient",
    "name": "zhmcclient",
    "maintainer": "Andreas Maier, Kathir Velusamy",
    "docs_url": null,
    "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
    "maintainer_email": "maiera@de.ibm.com, kathir.velu@in.ibm.com",
    "keywords": "",
    "author": "Juergen Leopold, Andreas Maier",
    "author_email": "leopoldj@de.ibm.com, maiera@de.ibm.com",
    "download_url": "https://files.pythonhosted.org/packages/21/6f/7b4a2ed8bb28011872fdfa54cc29a1c18bfe10771cf80a6161e59d8970ca/zhmcclient-1.14.0.tar.gz",
    "platform": "any",
    "description": ".. Copyright 2016,2021 IBM Corp. All Rights Reserved.\n..\n.. Licensed under the Apache License, Version 2.0 (the \"License\");\n.. you may not use this file except in compliance with the License.\n.. You may obtain a copy of the License at\n..\n..    http://www.apache.org/licenses/LICENSE-2.0\n..\n.. Unless required by applicable law or agreed to in writing, software\n.. distributed under the License is distributed on an \"AS IS\" BASIS,\n.. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n.. See the License for the specific language governing permissions and\n.. limitations under the License.\n..\n\nzhmcclient - A pure Python client library for the IBM Z HMC Web Services API\n============================================================================\n\n.. PyPI download statistics are broken, but the new PyPI warehouse makes PyPI\n.. download statistics available through Google BigQuery\n.. (https://bigquery.cloud.google.com).\n.. Query to list package downloads by version:\n..\n   SELECT\n     file.project,\n     file.version,\n     COUNT(*) as total_downloads,\n     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r\"^([^\\.]+\\.[^\\.]+)\") = \"2.6\" THEN 1 ELSE 0 END) as py26_downloads,\n     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r\"^([^\\.]+\\.[^\\.]+)\") = \"2.7\" THEN 1 ELSE 0 END) as py27_downloads,\n     SUM(CASE WHEN REGEXP_EXTRACT(details.python, r\"^([^\\.]+)\\.[^\\.]+\") = \"3\" THEN 1 ELSE 0 END) as py3_downloads,\n   FROM\n     TABLE_DATE_RANGE(\n       [the-psf:pypi.downloads],\n       TIMESTAMP(\"19700101\"),\n       CURRENT_TIMESTAMP()\n     )\n   WHERE\n     file.project = 'zhmcclient'\n   GROUP BY\n     file.project, file.version\n   ORDER BY\n     file.version DESC\n\n.. image:: https://img.shields.io/pypi/v/zhmcclient.svg\n    :target: https://pypi.python.org/pypi/zhmcclient/\n    :alt: Version on Pypi\n\n.. # .. image:: https://img.shields.io/pypi/dm/zhmcclient.svg\n.. #     :target: https://pypi.python.org/pypi/zhmcclient/\n.. #     :alt: Pypi downloads\n\n.. image:: https://github.com/zhmcclient/python-zhmcclient/actions/workflows/test.yml/badge.svg?branch=master\n    :target: https://github.com/zhmcclient/python-zhmcclient/actions/workflows/test.yml?query=branch%3Amaster\n    :alt: Test status (master)\n\n.. image:: https://readthedocs.org/projects/python-zhmcclient/badge/?version=latest\n    :target: https://readthedocs.org/projects/python-zhmcclient/builds/\n    :alt: Docs status (master)\n\n.. image:: https://coveralls.io/repos/github/zhmcclient/python-zhmcclient/badge.svg?branch=master\n    :target: https://coveralls.io/github/zhmcclient/python-zhmcclient?branch=master\n    :alt: Test coverage (master)\n\n.. image:: https://codeclimate.com/github/zhmcclient/python-zhmcclient/badges/gpa.svg\n    :target: https://codeclimate.com/github/zhmcclient/python-zhmcclient\n    :alt: CodeClimate status\n\n.. contents:: Contents:\n   :local:\n\nOverview\n========\n\nThe zhmcclient package is a client library\nwritten in pure Python that interacts with the Web Services API of the Hardware\nManagement Console (HMC) of `IBM Z`_ or `LinuxONE`_ machines. The goal of\nthis package is to make the HMC Web Services API easily consumable for Python\nprogrammers.\n\n.. _IBM Z: http://www.ibm.com/systems/z/\n.. _LinuxONE: http://www.ibm.com/systems/linuxone/\n\nThe HMC Web Services API is the access point for any external tools to\nmanage the IBM Z  or LinuxONE platform. It supports management of the\nlifecycle and configuration of various platform resources, such as partitions,\nCPU, memory, virtual switches, I/O adapters, and more.\n\nThe zhmcclient package encapsulates both protocols supported by the HMC Web\nServices API:\n\n* REST over HTTPS for request/response-style operations driven by the client.\n  Most of these operations complete synchronously, but some long-running tasks\n  complete asynchronously.\n\n* JMS (Java Messaging Services) for notifications from the HMC to the client.\n  This can be used to be notified about changes in the system, or about\n  completion of asynchronous tasks started using REST.\n\nInstallation\n============\n\nThe quick way:\n\n.. code-block:: bash\n\n    $ pip install zhmcclient\n\nFor more details, see the `Installation section`_ in the documentation.\n\n.. _Installation section: http://python-zhmcclient.readthedocs.io/en/latest/intro.html#installation\n\nQuickstart\n===========\n\nThe following example code lists the partitions on CPCs in DPM mode that are\naccessible for the user:\n\n.. code-block:: python\n\n    #!/usr/bin/env python\n\n    import zhmcclient\n    import requests.packages.urllib3\n    requests.packages.urllib3.disable_warnings()\n\n    # Set these variables for your environment:\n    host = \"<IP address or hostname of the HMC>\"\n    userid = \"<userid on that HMC>\"\n    password = \"<password of that HMC userid>\"\n    verify_cert = False\n\n    session = zhmcclient.Session(host, userid, password, verify_cert=verify_cert)\n    client = zhmcclient.Client(session)\n    console = client.consoles.console\n\n    partitions = console.list_permitted_partitions()\n    for part in partitions:\n        cpc = part.manager.parent\n        print(\"{} {}\".format(cpc.name, part.name))\n\nPossible output when running the script:\n\n.. code-block:: text\n\n    P000S67B PART1\n    P000S67B PART2\n    P0000M96 PART1\n\nDocumentation and Change Log\n============================\n\nFor the latest released version on PyPI:\n\n* `Documentation`_\n* `Change log`_\n\n.. _Documentation: http://python-zhmcclient.readthedocs.io/en/latest/\n.. _Change log: http://python-zhmcclient.readthedocs.io/en/latest/changes.html\n\nzhmc CLI\n========\n\nBefore version 0.18.0 of the zhmcclient package, it contained the zhmc CLI.\nStarting with zhmcclient version 0.18.0, the zhmc CLI has been moved from this\nproject into the new `zhmccli project`_.\n\nIf your project uses the zhmc CLI, and you are upgrading the zhmcclient\npackage from before 0.18.0 to 0.18.0 or later, your project will need to add\nthe `zhmccli package`_ to its dependencies.\n\n.. _zhmccli project: https://github.com/zhmcclient/zhmccli\n\n.. _zhmccli package: https://pypi.python.org/pypi/zhmccli\n\n\nContributing\n============\n\nFor information on how to contribute to this project, see the\n`Development section`_ in the documentation.\n\n.. _Development section: http://python-zhmcclient.readthedocs.io/en/latest/development.html\n\nLicense\n=======\n\nThe zhmcclient package is licensed under the `Apache 2.0 License`_.\n\n.. _Apache 2.0 License: https://github.com/zhmcclient/python-zhmcclient/tree/master/LICENSE\n",
    "bugtrack_url": null,
    "license": "Apache License, Version 2.0",
    "summary": "A pure Python client library for the IBM Z HMC Web Services API.",
    "version": "1.14.0",
    "project_urls": {
        "Bug Tracker": "https://github.com/zhmcclient/python-zhmcclient/issues",
        "Change Log": "https://python-zhmcclient.readthedocs.io/en/stable/changes.html",
        "Documentation": "https://python-zhmcclient.readthedocs.io/en/stable/",
        "Homepage": "https://github.com/zhmcclient/python-zhmcclient"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "058ec2db9cace27bd36a4f8b2765dfd5b09b133921d757bafe2fb7bc215219b7",
                "md5": "5f521c6d92efbe9aa289693398ffb1e5",
                "sha256": "ce0afe48bb87776fcf6e6104aec2abe5dc5374e1368cfbb4ac398bcf339becfe"
            },
            "downloads": -1,
            "filename": "zhmcclient-1.14.0-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5f521c6d92efbe9aa289693398ffb1e5",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
            "size": 305072,
            "upload_time": "2024-02-17T12:09:33",
            "upload_time_iso_8601": "2024-02-17T12:09:33.584711Z",
            "url": "https://files.pythonhosted.org/packages/05/8e/c2db9cace27bd36a4f8b2765dfd5b09b133921d757bafe2fb7bc215219b7/zhmcclient-1.14.0-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "216f7b4a2ed8bb28011872fdfa54cc29a1c18bfe10771cf80a6161e59d8970ca",
                "md5": "a59cc1cb5b7979fce4628c8565517f2a",
                "sha256": "6c406bd778762108b3beec034425757784b6eb5964487dae1945bd813e4eb7ab"
            },
            "downloads": -1,
            "filename": "zhmcclient-1.14.0.tar.gz",
            "has_sig": false,
            "md5_digest": "a59cc1cb5b7979fce4628c8565517f2a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
            "size": 242338,
            "upload_time": "2024-02-17T12:09:35",
            "upload_time_iso_8601": "2024-02-17T12:09:35.618291Z",
            "url": "https://files.pythonhosted.org/packages/21/6f/7b4a2ed8bb28011872fdfa54cc29a1c18bfe10771cf80a6161e59d8970ca/zhmcclient-1.14.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-02-17 12:09:35",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "zhmcclient",
    "github_project": "python-zhmcclient",
    "travis_ci": true,
    "coveralls": true,
    "github_actions": true,
    "requirements": [],
    "tox": true,
    "lcname": "zhmcclient"
}
        
Elapsed time: 0.19209s