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

chore: add full NCP CR example #993

Merged
merged 1 commit into from
Jul 25, 2024
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
42 changes: 42 additions & 0 deletions config/samples/mellanox.com_v1alpha1_nicclusterpolicy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,45 @@ spec:
}
]
}
sriovDevicePlugin:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rollandf secondaryNetwork ipoib is also applicable on openshift

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

image: sriov-network-device-plugin
repository: ghcr.io/k8snetworkplumbingwg
version: v3.7.0
config: |
{
"resourceList": [
{
"resourcePrefix": "nvidia.com",
"resourceName": "hostdev",
"selectors": {
"vendors": ["15b3"],
"isRdma": true
}
}
]
}
nvIpam:
image: nvidia-k8s-ipam
repository: ghcr.io/mellanox
version: v0.2.0
enableWebhook: false
ibKubernetes:
image: ib-kubernetes
repository: ghcr.io/mellanox
version: v1.0.2
pKeyGUIDPoolRangeStart: "02:00:00:00:00:00:00:00"
pKeyGUIDPoolRangeEnd: "02:FF:FF:FF:FF:FF:FF:FF"
ufmSecret: ufm-secret
nicFeatureDiscovery:
image: nic-feature-discovery
repository: ghcr.io/mellanox
version: v0.0.1
docaTelemetryService:
image: doca_telemetry
repository: nvcr.io/nvidia/doca
version: 1.16.5-doca2.6.0-host
secondaryNetwork:
ipoib:
image: ipoib-cni
repository: ghcr.io/mellanox
version: v1.2.0
118 changes: 118 additions & 0 deletions example/crs/mellanox.com_v1alpha1_nicclusterpolicy_cr-full.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
# 2024 NVIDIA CORPORATION & AFFILIATES
#
# 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.
#
# ##### Note #####
# This example contains all the components supported as a reference.
# User should edit the example and keep only the required components.
#
Comment on lines +14 to +18
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
#
# ##### Note #####
# This example contains all the components supported as a reference.
# User should edit the example and keep only the required components.
#

nit: do we need this example text or should we rather remove it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This example is a reference, that was asked from QA team to easily get the components versions, taking into account that in the future these versions will not be available in the Helm values.
This configuration probably is not a real life scenario.

apiVersion: mellanox.com/v1alpha1
kind: NicClusterPolicy
metadata:
name: nic-cluster-policy
spec:
ofedDriver:
image: doca-driver
repository: nvcr.io/nvstaging/mellanox
version: 24.07-0.3.2.0-0
upgradePolicy:
autoUpgrade: true
drain:
deleteEmptyDir: true
enable: true
force: true
timeoutSeconds: 300
maxParallelUpgrades: 1
startupProbe:
initialDelaySeconds: 10
periodSeconds: 10
livenessProbe:
initialDelaySeconds: 30
periodSeconds: 30
readinessProbe:
initialDelaySeconds: 10
periodSeconds: 30
rdmaSharedDevicePlugin:
image: k8s-rdma-shared-dev-plugin
repository: ghcr.io/mellanox
version: v1.5.1
# The config below directly propagates to k8s-rdma-shared-device-plugin configuration.
# Replace 'devices' with your (RDMA capable) netdevice name.
config: |
{
"configList": [
{
"resourceName": "rdma_shared_device_a",
"rdmaHcaMax": 63,
"selectors": {
"vendors": ["15b3"],
"deviceIDs": ["101b"]
}
}
]
}
sriovDevicePlugin:
image: sriov-network-device-plugin
repository: ghcr.io/k8snetworkplumbingwg
version: v3.7.0
config: |
{
"resourceList": [
{
"resourcePrefix": "nvidia.com",
"resourceName": "hostdev",
"selectors": {
"vendors": ["15b3"],
"isRdma": true
}
}
]
}
secondaryNetwork:
cniPlugins:
image: plugins
repository: ghcr.io/k8snetworkplumbingwg
version: v1.5.0
ipoib:
image: ipoib-cni
repository: ghcr.io/mellanox
version: v1.2.0
multus:
image: multus-cni
repository: ghcr.io/k8snetworkplumbingwg
version: v3.9.3
config: ''
ipamPlugin:
image: whereabouts
repository: ghcr.io/k8snetworkplumbingwg
version: v0.7.0
nvIpam:
image: nvidia-k8s-ipam
repository: ghcr.io/mellanox
version: v0.2.0
enableWebhook: false
ibKubernetes:
image: ib-kubernetes
repository: ghcr.io/mellanox
version: v1.0.2
pKeyGUIDPoolRangeStart: "02:00:00:00:00:00:00:00"
pKeyGUIDPoolRangeEnd: "02:FF:FF:FF:FF:FF:FF:FF"
ufmSecret: ufm-secret
nicFeatureDiscovery:
image: nic-feature-discovery
repository: ghcr.io/mellanox
version: v0.0.1
docaTelemetryService:
image: doca_telemetry
repository: nvcr.io/nvidia/doca
version: 1.16.5-doca2.6.0-host
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
# 2024 NVIDIA CORPORATION & AFFILIATES
#
# 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.
#
# ##### Note #####
# This example contains all the components supported as a reference.
# User should edit the example and keep only the required components.
#
apiVersion: mellanox.com/v1alpha1
kind: NicClusterPolicy
metadata:
name: nic-cluster-policy
spec:
ofedDriver:
image: {{ .Mofed.Image }}
repository: {{ .Mofed.Repository }}
version: {{ .Mofed.Version }}
upgradePolicy:
autoUpgrade: true
drain:
deleteEmptyDir: true
enable: true
force: true
timeoutSeconds: 300
maxParallelUpgrades: 1
startupProbe:
initialDelaySeconds: 10
periodSeconds: 10
livenessProbe:
initialDelaySeconds: 30
periodSeconds: 30
readinessProbe:
initialDelaySeconds: 10
periodSeconds: 30
rdmaSharedDevicePlugin:
image: {{ .RdmaSharedDevicePlugin.Image }}
repository: {{ .RdmaSharedDevicePlugin.Repository }}
version: {{ .RdmaSharedDevicePlugin.Version }}
# The config below directly propagates to k8s-rdma-shared-device-plugin configuration.
# Replace 'devices' with your (RDMA capable) netdevice name.
config: |
{
"configList": [
{
"resourceName": "rdma_shared_device_a",
"rdmaHcaMax": 63,
"selectors": {
"vendors": ["15b3"],
"deviceIDs": ["101b"]
}
}
]
}
sriovDevicePlugin:
image: {{ .SriovDevicePlugin.Image }}
repository: {{ .SriovDevicePlugin.Repository }}
version: {{ .SriovDevicePlugin.Version }}
config: |
{
"resourceList": [
{
"resourcePrefix": "nvidia.com",
"resourceName": "hostdev",
"selectors": {
"vendors": ["15b3"],
"isRdma": true
}
}
]
}
secondaryNetwork:
cniPlugins:
image: {{ .CniPlugins.Image }}
repository: {{ .CniPlugins.Repository }}
version: {{ .CniPlugins.Version }}
ipoib:
image: {{ .Ipoib.Image }}
repository: {{ .Ipoib.Repository }}
version: {{ .Ipoib.Version }}
multus:
image: {{ .Multus.Image }}
repository: {{ .Multus.Repository }}
version: {{ .Multus.Version }}
config: ''
ipamPlugin:
image: {{ .IpamPlugin.Image }}
repository: {{ .IpamPlugin.Repository }}
version: {{ .IpamPlugin.Version }}
nvIpam:
image: {{ .NvIPAM.Image }}
repository: {{ .NvIPAM.Repository }}
version: {{ .NvIPAM.Version }}
enableWebhook: false
ibKubernetes:
image: {{ .IbKubernetes.Image }}
repository: {{ .IbKubernetes.Repository }}
version: {{ .IbKubernetes.Version }}
pKeyGUIDPoolRangeStart: "02:00:00:00:00:00:00:00"
pKeyGUIDPoolRangeEnd: "02:FF:FF:FF:FF:FF:FF:FF"
ufmSecret: ufm-secret
nicFeatureDiscovery:
image: {{ .NicFeatureDiscovery.Image }}
repository: {{ .NicFeatureDiscovery.Repository }}
version: {{ .NicFeatureDiscovery.Version }}
docaTelemetryService:
image: {{ .DOCATelemetryService.Image }}
repository: {{ .DOCATelemetryService.Repository }}
version: {{ .DOCATelemetryService.Version }}
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,45 @@ spec:
}
]
}
sriovDevicePlugin:
image: {{ .SriovDevicePlugin.Image }}
repository: {{ .SriovDevicePlugin.Repository }}
version: {{ .SriovDevicePlugin.Version }}
config: |
{
"resourceList": [
{
"resourcePrefix": "nvidia.com",
"resourceName": "hostdev",
"selectors": {
"vendors": ["15b3"],
"isRdma": true
}
}
]
}
nvIpam:
image: {{ .NvIPAM.Image }}
repository: {{ .NvIPAM.Repository }}
version: {{ .NvIPAM.Version }}
enableWebhook: false
ibKubernetes:
image: {{ .IbKubernetes.Image }}
repository: {{ .IbKubernetes.Repository }}
version: {{ .IbKubernetes.Version }}
pKeyGUIDPoolRangeStart: "02:00:00:00:00:00:00:00"
pKeyGUIDPoolRangeEnd: "02:FF:FF:FF:FF:FF:FF:FF"
ufmSecret: ufm-secret
nicFeatureDiscovery:
image: {{ .NicFeatureDiscovery.Image }}
repository: {{ .NicFeatureDiscovery.Repository }}
version: {{ .NicFeatureDiscovery.Version }}
docaTelemetryService:
image: {{ .DOCATelemetryService.Image }}
repository: {{ .DOCATelemetryService.Repository }}
version: {{ .DOCATelemetryService.Version }}
secondaryNetwork:
ipoib:
image: {{ .Ipoib.Image }}
repository: {{ .Ipoib.Repository }}
version: {{ .Ipoib.Version }}
Loading