diff --git a/docs/advanced/index.md b/docs/advanced/index.md index 5c2e189d..3827c716 100644 --- a/docs/advanced/index.md +++ b/docs/advanced/index.md @@ -1,7 +1,7 @@ --- title: "Advanced" layout: default -sort: 2 +sort: 3 --- # Advanced diff --git a/docs/contributing/index.md b/docs/contributing/index.md index 09d91e69..49c0f558 100644 --- a/docs/contributing/index.md +++ b/docs/contributing/index.md @@ -1,7 +1,7 @@ --- title: "Contributing" layout: default -sort: 3 +sort: 4 --- # Contributing diff --git a/docs/deployment/helm.md b/docs/deployment/helm.md index da3db05c..51b37bfe 100644 --- a/docs/deployment/helm.md +++ b/docs/deployment/helm.md @@ -5,9 +5,11 @@ sort: 2 --- # Deployment with Helm + {: .no_toc} ## Table of contents + {: .no_toc .text-delta} 1. TOC @@ -17,9 +19,9 @@ sort: 2 Helm chart allow to easily deploy and manage the NFD-operator. -> NOTE: NFD-operator is not ideal for other Helm charts to depend on as that may result -> in multiple parallel NFD-operator deployments in the same cluster which is not fully -> supported by the NFD-operator Helm chart. +> NOTE: NFD-operator is not ideal for other Helm charts to depend on as that +> may result in multiple parallel NFD-operator deployments in the same cluster +> which is not fully supported by the NFD-operator Helm chart. ## Prerequisites @@ -107,4 +109,4 @@ We have introduced the following Chart parameters. | `controller.image.repository` | string | `{{ site.container_image | split: ":" | first }}` | NFD-Operator image repository | | `controller.image.tag` | string | `{{ site.release }}` | NFD-Operator image tag | -[rbac]: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ \ No newline at end of file +[rbac]: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ diff --git a/docs/deployment/image-variants.md b/docs/deployment/image-variants.md index 0442a09a..272b3e09 100644 --- a/docs/deployment/image-variants.md +++ b/docs/deployment/image-variants.md @@ -1,13 +1,15 @@ --- title: "Image variants" layout: default -sort: 1 +sort: 4 --- # Image variants + {: .no_toc} ## Table of contents + {: .no_toc .text-delta} 1. TOC @@ -15,24 +17,23 @@ sort: 1 --- -NFD-Operator currently offers two variants of the container image. The "minimal" variant is -currently deployed by default. Released container images are available for -x86_64 and Arm64 architectures. +# Image variants -## Minimal +Node-Feautre-Discovery-Operator currently offers two variants +of the container image. The "full" variant is currently +deployed by default. -This is a minimal image based on +## Default + +This is a minimal image based on: [gcr.io/distroless/base](https://github.com/GoogleContainerTools/distroless/blob/master/base/README.md) -and only supports running statically linked binaries. -For backwards compatibility a container image tag with suffix `-minimal` -(e.g. `{{ site.container_image }}-minimal`) is provided. +The container image tag has suffix `-minimal` +(e.g. `{{ site.container_image }}-minimal`) +and the image is deployed by default. ## Full -This image is based on [debian:bullseye-slim](https://hub.docker.com/_/debian) -and contains a full Linux system for running shell-based nfd-worker hooks and -doing live debugging and diagnosis of the NFD-Operator images. - -The container image tag has suffix `-full` -(e.g. `{{ site.container_image }}-full`). \ No newline at end of file +This image is based on +[debian:buster-slim](https://hub.docker.com/_/debian) and contains a full Linux +system for doing live debugging and diagnosis of the operator. diff --git a/docs/deployment/index.md b/docs/deployment/index.md new file mode 100644 index 00000000..6bff538e --- /dev/null +++ b/docs/deployment/index.md @@ -0,0 +1,19 @@ +--- +title: "Deployment" +layout: default +sort: 2 +--- + +# Deployment + +[Installation](manual) provides instructions for installing NFD-Operator to a +cluster. + +[Uninstallation](manual) provides instructions for removing NFD-Operator from a +cluster. + +[Using Helm](helm) provides easy management of NFD-Operator deployments with +nice configuration management and easy upgrades. + +See [Image variants](image-variants) for description of the different NFD-Operator +container images available. diff --git a/docs/get-started/quick-start.md b/docs/deployment/manual.md similarity index 55% rename from docs/get-started/quick-start.md rename to docs/deployment/manual.md index a9d99e49..862788bc 100644 --- a/docs/get-started/quick-start.md +++ b/docs/deployment/manual.md @@ -1,16 +1,28 @@ --- -title: "Quick start" +title: "Manual deployment" layout: default -sort: 2 +sort: 1 --- +# Manual deployment + +{: .no_toc} + +## Table of contents + +{: .no_toc .text-delta} + +1. TOC +{:toc} + +--- # Requirements 1. Linux (x86_64/Arm64/Arm) 1. [kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl) (properly set up and configured to work with your Kubernetes cluster) -# Quick start +# Manual deployment Get the source code @@ -41,27 +53,6 @@ Create a NodeFeatureDiscovery instance kubectl apply -f config/samples/nfd.kubernetes.io_v1_nodefeaturediscovery.yaml ``` -## Image variants - -Node-Feautre-Discovery-Operator currently offers two variants -of the container image. The "full" variant is currently -deployed by default. - -### Full - -This image is based on -[debian:buster-slim](https://hub.docker.com/_/debian) and contains a full Linux -system for doing live debugging and diagnosis of the operator. - -### Minimal - -This is a minimal image based on -[gcr.io/distroless/base](https://github.com/GoogleContainerTools/distroless/blob/master/base/README.md) -and only supports running statically linked binaries. - -The container image tag has suffix `-minimal` -(e.g. `{{ site.container_image }}-minimal`) - ## Verify The Operator will deploy NFD based on the information @@ -88,3 +79,42 @@ $ kubectl get no -o json | jq .items[].metadata.labels "kubernetes.io/os": "linux", ... ``` + +# Uninstallation + +If you followed the deployment instructions from the [Quick start](index) you +can simply do: + +```bash +kubectl -n nfd-operator delete NodeFeatureDiscovery my-nfd-deployment +``` + +Optionally, you can also remove the namespace: + +```bash +kubectl delete ns nfd-operator +``` + +See the [node-feature-discovery-operator][nfd-operator] and [OLM][OLM] project +documentation for instructions for uninstalling the operator and operator +lifecycle manager, respectively. + +## Removing feature labels + +From the [Operand repository][nfd] NFD-Master has a special `-prune` command +line flag for removing all nfd-related node labels, annotations and extended +resources from the cluster. + +```bash +kubectl apply -k https://github.com/kubernetes-sigs/node-feature-discovery/deployment/overlays/prune?ref={{ site.release }} +kubectl -n node-feature-discovery wait job.batch/nfd-master --for=condition=complete && \ + kubectl delete -k https://github.com/kubernetes-sigs/node-feature-discovery/deployment/overlays/prune?ref={{ site.release }} +``` + +**NOTE:** You must run prune before removing the RBAC rules (serviceaccount, +clusterrole and clusterrolebinding). + + +[nfd-operator]: https://github.com/kubernetes-sigs/node-feature-discovery-operator +[nfd]: https://github.com/kubernetes-sigs/node-feature-discovery +[OLM]: https://github.com/operator-framework/operator-lifecycle-manager diff --git a/docs/get-started/index.md b/docs/get-started/index.md index 2ef74ba5..69674597 100644 --- a/docs/get-started/index.md +++ b/docs/get-started/index.md @@ -15,5 +15,8 @@ Continue to: - **[Introduction](introduction.md)** for more details on the project. -- **[Quick start](quick-start.md)** for quick step-by-step - instructions on how to get NFD running on your cluster. +- **[Deployment](deployment/index.md)** for instructions on how to + deploy NFD-Operator to a cluster. + +- **[Advanced](advanced/index.md)** for more advanced topics and + reference.