Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: hpe-container-platform-community/hpecp-python-library
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.20.1
Choose a base ref
...
head repository: hpe-container-platform-community/hpecp-python-library
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Loading
72 changes: 72 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ "master" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
schedule:
- cron: '37 0 * * 3'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'python' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality


# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -71,7 +71,7 @@ jobs:
make html
touch ./build/html/.nojekyll
- name: Deploy to GitHub Pages
uses: JamesIves/github-pages-deploy-action@3.5.5
uses: JamesIves/github-pages-deploy-action@v4.2.5
with:
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
BRANCH: gh-pages
2 changes: 1 addition & 1 deletion .gitpod.Dockerfile
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@ RUN sudo apt-get -q update && sudo apt-get install -y shellcheck tox python3-sph
ENV PATH=$PATH:/home/gitpod/.local/bin

# setup the gitpod bundled python
RUN /home/gitpod/.pyenv/versions/2.7.*/bin/python2 -m pip install --upgrade pip
# RUN /home/gitpod/.pyenv/versions/2.7.*/bin/python2 -m pip install --upgrade pip
RUN /home/gitpod/.pyenv/versions/3.8.*/bin/python3 -m pip install --upgrade pip

# additional python versions
101 changes: 101 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -2,6 +2,107 @@

<!--next-version-placeholder-->

## v0.22.13 (2022-06-20)
### Fix
* **run_kubectl_command:** With apply typos fixed ([`054029e`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/054029eb85aaee33a2c1bb252b90cfcbddfd56fc))

## v0.22.12 (2022-06-20)
### Fix
* **cli:** Bump minor release ([`a54a076`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/a54a07622152be28fee14faac0f2b496668a0494))

## v0.22.11 (2022-06-20)
### Fix
* **cli:** Add run-kubernetes-command ([`44b0a07`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/44b0a07a17f2f0c1550c4b2b2f4738948bf3a94a))

## v0.22.10 (2022-03-14)
### Fix
* **gateway:** Issue with params ([`e0b14f0`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/e0b14f06b8e2c1353ce76ad4b48ea89d9f2af038))

## v0.22.9 (2022-02-23)
### Fix
* **ssh:** Ssh key passphrase ([`555a7c3`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/555a7c3568179457e7077693cd53df52416cc0cc))

## v0.22.8 (2022-02-23)
### Fix
* **ssh:** Ssh key passphrase ([`1528e19`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/1528e19394f52b8ac2b83c088b51546b9b3e1a50))

## v0.22.7 (2022-02-22)
### Fix
* **ssh:** Ssh key passphrase ([`b3589c5`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/b3589c5a82c78263b6e419e0a5e7322430fcd188))

## v0.22.6 (2022-02-21)
### Fix
* **k8sworker:** Ssh passphrase ([`c9d3849`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/c9d3849e56ccab0e946150bdcc517ca6fbeb407a))

## v0.22.5 (2022-02-21)
### Fix
* **gateway:** Missing arg ([`c5d0d21`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/c5d0d21b3fab24b2c2220dbe6f9814a8161d1192))

## v0.22.4 (2022-02-21)
### Fix
* **build:** Fix broken build ([`9ee71bf`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/9ee71bf01e824f9200ce6e4e09b94ff8ad5583ca))

## v0.22.3 (2022-02-21)
### Fix
* **build:** Fix broken build ([`7d5f2ee`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/7d5f2ee88c218a4d40d59949eedfb8abfbca3712))

## v0.22.2 (2021-12-01)
### Fix
* **cli:** Better err msg for k8s_version parameter ([`d32f2b5`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/d32f2b5700a6a1b8ebd272afbfff47ffbb3f8c00))

## v0.22.1 (2021-05-14)
### Fix
* **k8scluster:** Meta ([`d82b954`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/d82b95497ee1cb86d2ae22c86dba6af5830a32dc))

## v0.22.0 (2021-05-14)
### Feature
* **k8scluster:** Add supported cluster types ([`2271b58`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/2271b583060a0fb0dcd21e2c9b0595a0ba5759f4))

## v0.21.7 (2021-05-11)
### Fix
* **k8scluster:** Formatting ([`292bc94`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/292bc94c49f16cace1e24390812cabc171801ce9))
* **k8scluster:** Persistent storage ([`79a8745`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/79a8745feef73dcacbd18a1bfe86df65401eb9d4))

## v0.21.6 (2021-04-21)
### Fix
* **k8scluster:** Remove persistent storage if addons ([`e3eb5fa`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/e3eb5fafc1096c2bfbc528fdfe9bc9920d30c9eb))

## v0.21.5 (2021-03-29)
### Fix
* **k8sworker:** Fix typos ([`f7619b4`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/f7619b41127545dd56bde21da4a1a012212f4f72))

## v0.21.4 (2021-03-29)
### Fix
* **k8sworker:** Tidy up ([`469e798`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/469e79894d14fc779c9bfdb65bc9234b7e42b051))

## v0.21.3 (2021-03-29)
### Fix
* **k8sworker:** Fine grained create params ([`65b3269`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/65b32690b7303b61b552b0bb4eb0903a0fdb4e39))

## v0.21.2 (2021-03-28)
### Fix
* **k8scluster:** Better err handling ([`db57b13`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/db57b13e548e98f502501a8f325e8739384e02ca))

## v0.21.1 (2021-03-26)
### Fix
* **k8scluster:** Better validation of parms ([`c32b5db`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/c32b5dbe74c7f1f4860585605939bf4cafef3f6c))

## v0.21.0 (2021-03-22)
### Feature
* **k8scluster:** Support datafabric ([`a7bb00a`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/a7bb00aa11039a6b6220b2e1f164475644b85e27))

## v0.20.4 (2021-03-22)
### Fix
* **k8sworker:** Tags ([`b1dfa95`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/b1dfa957b7bc804983a5bcd0bd0b2e4376c9993d))

## v0.20.3 (2021-03-22)
### Fix
* **k8sworker:** Formatting ([`98ae245`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/98ae245398e4cc371758123a69172559a7fb48e5))

## v0.20.2 (2021-03-22)
### Fix
* **k8sworker:** Tags ([`21abc58`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/21abc583d02ae1a058e8143c7262f883df668912))

## v0.20.1 (2021-03-22)
### Fix
* **k8sworker:** Error messager ([`d0eb9fb`](https://github.com/hpe-container-platform-community/hpecp-python-library/commit/d0eb9fb403b9f502f46442d5fe5efae205e0dbaa))
13 changes: 4 additions & 9 deletions DEVELOPING.md
Original file line number Diff line number Diff line change
@@ -143,16 +143,11 @@ black hpecp

### RELEASING

- Not applicable while pre-alpha.
- Releasing is done using semantic releases.
- The commit message will determine the release numbering, e.g.
- `fix(sometext): fix message` - this will call a minor jump e.g. X.Y.Z to X.Y.Z+1
- `feat(sometext): feature message` - this will call a major jump e.g. X.Y.Z to X.Y+1.Z

```
vi setup.py # increment version
git add ...
git commit -m '...'
git tag 0.0.9 -m "Add pypi python versions"
git push origin 0.0.9
python setup.py sdist upload -r pypi
```

### TROUBLESHOOTING

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -13,7 +13,7 @@


----

## Documentation

See [here](https://hpe-container-platform-community.github.io/hpecp-python-library/index.html) for User Documentation.
4 changes: 2 additions & 2 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
@@ -3,8 +3,8 @@ Overview

Python library and Command Line Interface (CLI) for HPE Container Platform (HPECP).

This library is pre-alpha. The API of this library may be unstable and
subject to change until this library reaches beta.
This library is beta. The API of this library may be unstable and
subject to change until this library reaches GA.

Library Example
---------------
2 changes: 1 addition & 1 deletion docs/source/installation.rst
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
Installation
============

While this library is pre-alpha, it is recommended to install it with pip using the `--upgrade` flag so
While this library is beta, it is recommended to install it with pip using the `--upgrade` flag so
that you always get the latest version.

Note that until the API of this library will be unstable and subject to change until this library becomes beta.
2 changes: 1 addition & 1 deletion hpecp/__init__.py
Original file line number Diff line number Diff line change
@@ -35,4 +35,4 @@
)
from .logger import Logger

__version__ = "0.20.1"
__version__ = "0.22.13"
7 changes: 5 additions & 2 deletions hpecp/cli/base.py
Original file line number Diff line number Diff line change
@@ -55,7 +55,7 @@ def get_profile():
"""Retrieve the profile - if supplied."""
profile = os.getenv("PROFILE", default="default")
_log.debug(
"PROFILE envirionment variable exists with value '{}'".format(profile)
"PROFILE environment variable exists with value '{}'".format(profile)
)
return profile

@@ -164,7 +164,10 @@ def get(self, id, output="yaml", params=None):
self.client_module_property = getattr(
self.client, self.client_module_name
)
response = self.client_module_property.get(id=id, params=params)
if params:
response = self.client_module_property.get(id=id, params=params)
else:
response = self.client_module_property.get(id=id)
json_data = response.json

if output == "json":
4 changes: 4 additions & 0 deletions hpecp/cli/gateway.py
Original file line number Diff line number Diff line change
@@ -52,6 +52,7 @@ def create_with_ssh_key(
proxy_node_hostname,
ssh_key=None,
ssh_key_file=None,
ssh_passphrase=None,
tags=[],
):
"""Create a Gateway using SSH key authentication.
@@ -70,6 +71,8 @@ def create_with_ssh_key(
ssh_key_file: string
The file path to the ssh key. Alternatively, use the
ssh_key parameter.
ssh_passphrase: string
The passphrase
tags: string
Tags to add to the gateway, for example:
"{ 'tag1': 'foo', 'tag2', 'bar' }".
@@ -96,6 +99,7 @@ def create_with_ssh_key(
ip=ip,
proxy_node_hostname=proxy_node_hostname,
ssh_key_data=ssh_key,
ssh_passphrase=ssh_passphrase,
tags=tags,
)
print(gateway_id)
Loading