Skip to content

Commit 8f39598

Browse files
committed
Add toc generation and validation to VPA
Also add some TOC markers to existing markdown files, and run generate-toc on them
1 parent 86115b5 commit 8f39598

File tree

21 files changed

+258
-91
lines changed

21 files changed

+258
-91
lines changed

vertical-pod-autoscaler/README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,13 @@
22

33
## Contents
44

5-
- [Contents](#contents)
5+
<!-- toc -->
66
- [Intro](#intro)
7-
- [Getting started](#getting-started)
7+
- [Getting Started](#getting-started)
88
- [Components and Architecture](#components-and-architecture)
99
- [Features and Known limitations](#features-and-known-limitations)
1010
- [Related links](#related-links)
11+
<!-- /toc -->
1112

1213
## Intro
1314

vertical-pod-autoscaler/docs/components.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,18 @@
22

33
## Contents
44

5-
- [Components](#components)
6-
- [Introduction](#introduction)
7-
- [Recommender](#recommender)
8-
- [Running](#running-the-recommender)
9-
- [Implementation](#implementation-of-the-recommender)
10-
- [Updater](#updater)
11-
- [Current implementation](#current-implementation)
12-
- [Missing Parts](#missing-parts)
13-
- [Admission Controller](#admission-controller)
14-
- [Running](#running-the-admission-controller)
15-
- [Implementation](#implementation-of-the-admission-controller)
5+
<!-- toc -->
6+
- [Introduction](#introduction)
7+
- [Recommender](#recommender)
8+
- [Running the recommender](#running-the-recommender)
9+
- [Implementation of the recommender](#implementation-of-the-recommender)
10+
- [Updater](#updater)
11+
- [Current implementation](#current-implementation)
12+
- [Missing parts](#missing-parts)
13+
- [Admission-controller](#admission-controller)
14+
- [Running the admission-controller](#running-the-admission-controller)
15+
- [Implementation of the Admission Controller](#implementation-of-the-admission-controller)
16+
<!-- /toc -->
1617

1718
## Introduction
1819

vertical-pod-autoscaler/docs/examples.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,18 @@
22

33
## Contents
44

5-
- [Examples](#examples)
6-
- [Keeping limit proportional to request](#keeping-limit-proportional-to-request)
7-
- [Capping to Limit Range](#capping-to-limit-range)
8-
- [Resource Policy Overriding Limit Range](#resource-policy-overriding-limit-range)
9-
- [Starting multiple recommenders](#starting-multiple-recommenders)
10-
- [Using CPU management with static policy](#using-cpu-management-with-static-policy)
11-
- [Controlling eviction behavior based on scaling direction and resource](#controlling-eviction-behavior-based-on-scaling-direction-and-resource)
12-
- [Limiting which namespaces are used](#limiting-which-namespaces-are-used)
13-
- [Setting the webhook failurePolicy](#setting-the-webhook-failurepolicy)
14-
- [Specifying global maximum allowed resources to prevent pods from being unschedulable](#specifying-global-maximum-allowed-resources-to-prevent-pods-from-being-unschedulable)
5+
<!-- toc -->
6+
- [Keeping limit proportional to request](#keeping-limit-proportional-to-request)
7+
- [Capping to Limit Range](#capping-to-limit-range)
8+
- [Resource Policy Overriding Limit Range](#resource-policy-overriding-limit-range)
9+
- [Starting multiple recommenders](#starting-multiple-recommenders)
10+
- [Custom memory bump-up after OOMKill](#custom-memory-bump-up-after-oomkill)
11+
- [Using CPU management with static policy](#using-cpu-management-with-static-policy)
12+
- [Controlling eviction behavior based on scaling direction and resource](#controlling-eviction-behavior-based-on-scaling-direction-and-resource)
13+
- [Limiting which namespaces are used](#limiting-which-namespaces-are-used)
14+
- [Setting the webhook failurePolicy](#setting-the-webhook-failurepolicy)
15+
- [Specifying global maximum allowed resources to prevent pods from being unschedulable](#specifying-global-maximum-allowed-resources-to-prevent-pods-from-being-unschedulable)
16+
<!-- /toc -->
1517

1618
## Keeping limit proportional to request
1719

vertical-pod-autoscaler/docs/faq.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,19 @@
22

33
## Contents
44

5-
- [VPA restarts my pods but does not modify CPU or memory settings. Why?](#vpa-restarts-my-pods-but-does-not-modify-cpu-or-memory-settings)
5+
<!-- toc -->
6+
- [VPA restarts my pods but does not modify CPU or memory settings](#vpa-restarts-my-pods-but-does-not-modify-cpu-or-memory-settings)
67
- [How can I apply VPA to my Custom Resource?](#how-can-i-apply-vpa-to-my-custom-resource)
7-
- [How can I use Prometheus as a history provider for the VPA recommender?](#how-can-i-use-prometheus-as-a-history-provider-for-the-vpa-recommender)
8-
- [I get recommendations for my single pod replicaSet, but they are not applied. Why?](#i-get-recommendations-for-my-single-pod-replicaset-but-they-are-not-applied)
8+
- [How can I use Prometheus as a history provider for the VPA recommender](#how-can-i-use-prometheus-as-a-history-provider-for-the-vpa-recommender)
9+
- [I get recommendations for my single pod replicaset but they are not applied](#i-get-recommendations-for-my-single-pod-replicaset-but-they-are-not-applied)
910
- [Can I run the VPA in an HA configuration?](#can-i-run-the-vpa-in-an-ha-configuration)
1011
- [What are the parameters to VPA recommender?](#what-are-the-parameters-to-vpa-recommender)
1112
- [What are the parameters to VPA updater?](#what-are-the-parameters-to-vpa-updater)
12-
- [What are the parameters to VPA admission-controller?](#what-are-the-parameters-to-vpa-admission-controller)
13+
- [What are the parameters to VPA admission controller?](#what-are-the-parameters-to-vpa-admission-controller)
1314
- [How can I configure VPA to manage only specific resources?](#how-can-i-configure-vpa-to-manage-only-specific-resources)
1415
- [How can I have Pods in the kube-system namespace under VPA control in AKS?](#how-can-i-have-pods-in-the-kube-system-namespace-under-vpa-control-in-aks)
1516
- [How can I configure VPA when running in EKS with Cilium?](#how-can-i-configure-vpa-when-running-in-eks-with-cilium)
17+
<!-- /toc -->
1618

1719
### VPA restarts my pods but does not modify CPU or memory settings
1820

vertical-pod-autoscaler/docs/features.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,20 @@
22

33
## Contents
44

5+
<!-- toc -->
56
- [Limits control](#limits-control)
67
- [Memory Value Humanization](#memory-value-humanization)
78
- [CPU Recommendation Rounding](#cpu-recommendation-rounding)
89
- [Memory Recommendation Rounding](#memory-recommendation-rounding)
9-
- [In-Place Updates](#in-place-updates-inplaceorrecreate)
10+
- [In-Place Updates (<code>InPlaceOrRecreate</code>)](#in-place-updates-inplaceorrecreate)
11+
- [Usage](#usage)
12+
- [Behavior](#behavior)
13+
- [Requirements:](#requirements)
14+
- [Configuration](#configuration)
15+
- [Limitations](#limitations)
16+
- [Fallback Behavior](#fallback-behavior)
17+
- [Monitoring](#monitoring)
18+
<!-- /toc -->
1019

1120
## Limits control
1221

vertical-pod-autoscaler/docs/flags.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ To view the most recent _release_ of flags for all VPA components, consult the r
55

66
> **Note:** This document is auto-generated from the default branch (master) of the VPA repository.
77
8+
<!-- toc -->
9+
- [What are the parameters to VPA admission-controller?](#what-are-the-parameters-to-vpa-admission-controller)
10+
- [What are the parameters to VPA recommender?](#what-are-the-parameters-to-vpa-recommender)
11+
- [What are the parameters to VPA updater?](#what-are-the-parameters-to-vpa-updater)
12+
<!-- /toc -->
13+
814
# What are the parameters to VPA admission-controller?
915
This document is auto-generated from the flag definitions in the VPA admission-controller code.
1016

vertical-pod-autoscaler/docs/installation.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,16 @@
22

33
## Contents
44

5-
- [Installation](#installation)
6-
- [Compatibility](#compatibility)
7-
- [Notice on deprecation of v1beta2 version (>=0.13.0)](#notice-on-deprecation-of-v1beta2-version-0130)
8-
- [Notice on removal of v1beta1 version (>=0.5.0)](#notice-on-removal-of-v1beta1-version-050)
9-
- [Prerequisites](#prerequisites)
10-
- [Install command](#install-command)
11-
- [Tear down](#tear-down)
5+
<!-- toc -->
6+
- [Compatibility](#compatibility)
7+
- [Notice on CRD update (&gt;=1.0.0)](#notice-on-crd-update-100)
8+
- [Notice on deprecation of v1beta2 version (&gt;=0.13.0)](#notice-on-deprecation-of-v1beta2-version-0130)
9+
- [Notice on removal of v1beta1 version (&gt;=0.5.0)](#notice-on-removal-of-v1beta1-version-050)
10+
- [Prerequisites](#prerequisites)
11+
- [Install command](#install-command)
12+
- [Feature gates](#feature-gates)
13+
- [Tear down](#tear-down)
14+
<!-- /toc -->
1215

1316
The current default version is Vertical Pod Autoscaler 1.3.1
1417

vertical-pod-autoscaler/docs/known-limitations.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Known limitations
22

3+
<!-- toc -->
4+
<!-- /toc -->
5+
36
- Whenever VPA updates the pod resources, the pod is recreated, which causes all
47
running containers to be recreated. The pod may be recreated on a different
58
node.

vertical-pod-autoscaler/docs/quickstart.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,11 @@
22

33
## Contents
44

5-
- [Quick start](#quick-start)
6-
- [Test your installation](#test-your-installation)
7-
- [Example VPA configuration](#example-vpa-configuration)
8-
- [Troubleshooting](#troubleshooting)
5+
<!-- toc -->
6+
- [Test your installation](#test-your-installation)
7+
- [Example VPA configuration](#example-vpa-configuration)
8+
- [Troubleshooting](#troubleshooting)
9+
<!-- /toc -->
910

1011
After [installation](./installation.md) the system is ready to recommend and set
1112
resource requests for your pods.

vertical-pod-autoscaler/docs/sidecar-containers.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
11
# VPA Sidecar Container Management
22

3+
<!-- toc -->
4+
- [Understanding VPA and Container Policies](#understanding-vpa-and-container-policies)
5+
- [Default Container Policies](#default-container-policies)
6+
- [Default Behavior: Ignoring Sidecar Containers](#default-behavior-ignoring-sidecar-containers)
7+
- [The vpaObservedContainers Annotation](#the-vpaobservedcontainers-annotation)
8+
- [Webhook Ordering Importance](#webhook-ordering-importance)
9+
- [The Eviction Loop Problem](#the-eviction-loop-problem)
10+
- [Customizing VPA Behavior for Sidecar Containers](#customizing-vpa-behavior-for-sidecar-containers)
11+
- [Option 1: Webhook Ordering](#option-1-webhook-ordering)
12+
- [Option 2: Webhook Reinvocation](#option-2-webhook-reinvocation)
13+
- [Implementation Examples](#implementation-examples)
14+
- [Example 1: Istio Sidecar Integration](#example-1-istio-sidecar-integration)
15+
- [Example 2: Custom VPA Configuration with Sidecars](#example-2-custom-vpa-configuration-with-sidecars)
16+
<!-- /toc -->
17+
318
In this document, "sidecar container" refers to any additional Container that isn't the main application Container in a Pod. This is distinct from the [native Kubernetes sidecar pattern](https://kubernetes.io/docs/concepts/workloads/pods/sidecar-containers/), which makes use of `initContainers`. Our usage here applies to all additional regular `containers` only, as VPA does not support `initContainers` yet.
419

520
The Vertical Pod Autoscaler (VPA) has specific behavior when dealing with these additional containers that are injected into pods via admission webhooks.

0 commit comments

Comments
 (0)