Skip to main content

Wrapper around https://github.com/openshift/openshift-cluster-management-python-client

Project description

openshift-cluster-management-python-wrapper

Wrapper for openshift-cluster-management-python client

Release new version

requirements:

  • Export GitHub token
export GITHUB_TOKEN=<your_github_token>

Run the following once (execute outside repository dir, for example ~/):

sudo npm install --global release-it
npm install --save-dev @release-it/bumper

usage:

  • Create a release, run from the relevant branch.
    To create a 1.0 release, run:
git checkout v1.0
git pull
release-it # Follow the instructions

Installation

From source:

git clone https://github.com/RedHatQE/openshift-cluster-management-python-client.git
cd openshift-cluster-management-python-client
python setup.py install --user

Examples

Client

from ocm_python_wrapper.ocm_client import OCMPythonClient
ocm_client = OCMPythonClient(
    token=<ocm api token>>,
    endpoint=<endpoint url>,
    api_host=<production or stage>,
    discard_unknown_keys=True,
)
return ocm_client.client

Cluster

from ocm_python_wrapper.cluster import Cluster
cluster = Cluster(client=client, name=<cluster name>)
cluster_ocp_version = cluster.instance.version.raw_id

Project details


Release history Release notifications | RSS feed

This version

2.0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

File details

Details for the file openshift_cluster_management_python_wrapper-2.0.1.tar.gz.

File metadata

File hashes

Hashes for openshift_cluster_management_python_wrapper-2.0.1.tar.gz
Algorithm Hash digest
SHA256 92293ffcd91ae91a05b098612ca5624dc47302da2fd3873027c6d5944e246e06
MD5 2d176a8ed151209a7f57f20fa3d40bd7
BLAKE2b-256 8606a3037f224c9997b15f639ac881a35205225b1ae7aa28988a9f9d4edae971

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page