Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

merge branch develop-> main to release 2.4.1 #182

Merged
merged 6 commits into from
Sep 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Change Log

## [2.4.1](https://github.com/IBM/kubernetes-driver/tree/2.4.1) (2023-09-20)
[Full Changelog](https://github.com/IBM/kubernetes-driver/compare/2.4.0...2.4.1)

- Update helm to 3.12.3 to fix Vulnerabilitie [\#180](https://github.com/IBM/kubernetes-driver/issues/180)

## [2.4.0](https://github.com/IBM/kubernetes-driver/tree/2.4.0) (2023-07-27)
[Full Changelog](https://github.com/IBM/kubernetes-driver/compare/2.4.0-rc2...2.4.0)

Expand Down
6 changes: 3 additions & 3 deletions devdocs/dev-env.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ On ubuntu, you can do this using the same script used by the Dockerfile to bundl

```
chmod u+x ./docker/setup-helm.sh
./docker/setup-helm.sh 3.12.1
./docker/setup-helm.sh 3.12.3
```

Include as many versions as you need separated by spaces. Ensure the versions exist on the [Helm Github releases page](https://github.com/helm/helm/releases).
Expand All @@ -98,8 +98,8 @@ For other systems, look at the contents of the script to see the steps and adapt
- Download the version of the Helm you want
- Extract the archive
- Copy the `helm` binary included in the archive to any bin directory on your PATH
- Rename the `helm` binary to `helm$version` e.g helm3.12.1
- Run `helm3.12.1 --help` to verify this has worked
- Rename the `helm` binary to `helm$version` e.g helm3.12.3
- Run `helm3.12.3 --help` to verify this has worked

## Install the build dependencies

Expand Down
4 changes: 2 additions & 2 deletions devdocs/helm-chart.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ The Helm chart for this driver includes the following features:

# Build Helm Chart

To build the Helm chart you will need to install Helm v3.12.1
To build the Helm chart you will need to install Helm v3.12.3

## Full Build

Expand All @@ -34,7 +34,7 @@ python3 build.py --skip-docker

# Deploy Helm Chart

To deploy the Helm chart will need Helm v3.12.1 installed
To deploy the Helm chart will need Helm v3.12.3 installed

Install the chart with the default configuration using the install command:

Expand Down
2 changes: 1 addition & 1 deletion docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ ENV DRIVER_PORT ${DRIVER_PORT:-8294}
ARG NUM_PROCESSES
ENV NUM_PROCESSES ${NUM_PROCESSES:-4}
ARG SUPPORTED_HELM_VERSIONS
ENV SUPPORTED_HELM_VERSIONS ${SUPPORTED_HELM_VERSIONS:-3.12.1}
ENV SUPPORTED_HELM_VERSIONS ${SUPPORTED_HELM_VERSIONS:-3.12.3}

COPY whls/*.whl /whls/

Expand Down
2 changes: 1 addition & 1 deletion docs/user-guide/building-a-resource.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ For full details on templates and the syntax used, check out the [Templating](te

The Kubernetes driver can deploy any helm charts to your target Kubernetes environments as long as Helm3 has been installed on the environment.

The Helm charts must be compatible with Helm 3 (helm v.3.12.1 is included in the driver).
The Helm charts must be compatible with Helm 3 (helm v.3.12.3 is included in the driver).

The `helm` directory should include the packaged Helm charts you intend to install (`.tgz` files) and any values files you may use to configure the installation. We'll see how you install the charts and select your values file later.

Expand Down
4 changes: 2 additions & 2 deletions docs/user-guide/deployment-locations.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ The following properties are supported by the driver:
| clientConfig | - | Y | A multiline string version of the kubectl config file used to access the target cluster (see more details [below](#obtaining-clientconfig)) |
| defaultObjectNamespace | default | N | Sets the default namespace used when deploying Kubernetes objects on a create request. This value is only used when the object does not have a specified namespace in the metadata section of it's configuration |
| driverNamespace | Value of defaultObjectNamepsace/default_object_namespace | N | Sets the namespace to be used by the driver for any Kubernetes objects it creates for management purposes |
| helm.version | 3.12.1 | N | Determines the helm client version to use when deploying helm charts (allowed values: 3.12.1) |
| helm.version | 3.12.3 | N | Determines the helm client version to use when deploying helm charts (allowed values: 3.12.3) |
| helm.tls.cacert | - | N | Contents of the CA certificate (if used) |
| helm.tls.cert | - | N | Contents of the helm client certificate |
| helm.tls.key | - | N | Contents of the helm client key |

**Note:** when using Helm your target deployment location must be using a compatible server version for 3.12.1 (check with `helm version` on the server).
**Note:** when using Helm your target deployment location must be using a compatible server version for 3.12.3 (check with `helm version` on the server).

# Obtaining clientConfig

Expand Down
2 changes: 1 addition & 1 deletion kubedriver/location/deployment_location.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def from_dict(dl_data):
return KubeDeploymentLocation(name, client_config, **kwargs)

def __init__(self, name, client_config, default_object_namespace=DEFAULT_NAMESPACE, crd_api_version=None, driver_namespace=None, \
cm_api_version='v1', cm_kind='ConfigMap', cm_data_field='data', helm_version='3.12.1', helm_tls=None):
cm_api_version='v1', cm_kind='ConfigMap', cm_data_field='data', helm_version='3.12.3', helm_tls=None):
super().__init__(name, client_config, default_object_namespace=default_object_namespace)
self.crd_api_version = crd_api_version
self.cm_api_version = cm_api_version
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
'ignition-framework=={0}'.format(_pkg_info['ignition-version']),
'openshift==0.12.0',
'python-dateutil==2.8.1',
'RestrictedPython==5.2',
'RestrictedPython==5.3',
'gunicorn==20.1.0'
],
entry_points='''
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/helmclient/test_helm_client_3.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class TestHelmClient3(unittest.TestCase):
"""

def setUp(self):
self.client = HelmClient('kubeconfig', '3.12.1')
self.client = HelmClient('kubeconfig', '3.12.3')

def tearDown(self):
self.client.close()
Expand Down Expand Up @@ -120,7 +120,7 @@ def test_delete_command_error(self, mock_subprocess):

@patch('kubedriver.helmclient.client.subprocess')
def test_purge(self, mock_subprocess):
self.client = HelmClient('kubeconfig', '3.12.1')
self.client = HelmClient('kubeconfig', '3.12.3')
self.__mock_subprocess_response(mock_subprocess, 0, EXAMPLE_MANIFEST)
result = self.client.purge('name', 'namespace')
self.assertEqual(result, None)
Expand Down