mirror of
https://github.com/vmware-tanzu/velero.git
synced 2025-12-23 06:15:21 +00:00
Merge pull request #9167 from blackpiglet/fix_repository_maintenance_doc
Some checks failed
Run the E2E test on kind / build (push) Failing after 11m13s
Run the E2E test on kind / setup-test-matrix (push) Successful in 3s
Run the E2E test on kind / run-e2e-test (push) Has been skipped
Main CI / Build (push) Failing after 30s
Close stale issues and PRs / stale (push) Successful in 13s
Trivy Nightly Scan / Trivy nightly scan (velero, main) (push) Failing after 1m14s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-aws, main) (push) Failing after 1m23s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-gcp, main) (push) Failing after 1m9s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-microsoft-azure, main) (push) Failing after 1m8s
Some checks failed
Run the E2E test on kind / build (push) Failing after 11m13s
Run the E2E test on kind / setup-test-matrix (push) Successful in 3s
Run the E2E test on kind / run-e2e-test (push) Has been skipped
Main CI / Build (push) Failing after 30s
Close stale issues and PRs / stale (push) Successful in 13s
Trivy Nightly Scan / Trivy nightly scan (velero, main) (push) Failing after 1m14s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-aws, main) (push) Failing after 1m23s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-gcp, main) (push) Failing after 1m9s
Trivy Nightly Scan / Trivy nightly scan (velero-plugin-for-microsoft-azure, main) (push) Failing after 1m8s
Fix the repository-maintenance-job-configmap format issue in doc.
This commit is contained in:
@@ -60,47 +60,63 @@ This can be done by adding multiple entries in the `LoadAffinity` array.
|
|||||||
|
|
||||||
The sample of the ```repo-maintenance-job-configmap``` ConfigMap for the above scenario is as below:
|
The sample of the ```repo-maintenance-job-configmap``` ConfigMap for the above scenario is as below:
|
||||||
``` bash
|
``` bash
|
||||||
cat <<EOF > repo-maintenance-job-config.json
|
cat <<EOF > repo-maintenance-job-config.yaml
|
||||||
{
|
apiVersion: v1
|
||||||
"global": {
|
kind: ConfigMap
|
||||||
"podResources": {
|
metadata:
|
||||||
"cpuRequest": "100m",
|
name: repo-maintenance-job-config
|
||||||
"cpuLimit": "200m",
|
namespace: velero
|
||||||
"memoryRequest": "100Mi",
|
data:
|
||||||
"memoryLimit": "200Mi"
|
global: |
|
||||||
|
{
|
||||||
|
"podResources": {
|
||||||
|
"cpuRequest": "100m",
|
||||||
|
"cpuLimit": "200m",
|
||||||
|
"memoryRequest": "100Mi",
|
||||||
|
"memoryLimit": "200Mi"
|
||||||
|
},
|
||||||
|
"keepLatestMaintenanceJobs": 1,
|
||||||
|
"loadAffinity": [
|
||||||
|
{
|
||||||
|
"nodeSelector": {
|
||||||
|
"matchExpressions": [
|
||||||
|
{
|
||||||
|
"key": "cloud.google.com/machine-family",
|
||||||
|
"operator": "In",
|
||||||
|
"values": [
|
||||||
|
"e2"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"loadAffinity": [
|
{
|
||||||
{
|
"nodeSelector": {
|
||||||
"nodeSelector": {
|
"matchExpressions": [
|
||||||
"matchExpressions": [
|
{
|
||||||
{
|
"key": "topology.kubernetes.io/zone",
|
||||||
"key": "cloud.google.com/machine-family",
|
"operator": "In",
|
||||||
"operator": "In",
|
"values": [
|
||||||
"values": [
|
"us-central1-a",
|
||||||
"e2"
|
"us-central1-b",
|
||||||
]
|
"us-central1-c"
|
||||||
}
|
]
|
||||||
]
|
}
|
||||||
}
|
]
|
||||||
},
|
}
|
||||||
{
|
}
|
||||||
"nodeSelector": {
|
]
|
||||||
"matchExpressions": [
|
}
|
||||||
{
|
kibishii-default-kopia: |
|
||||||
"key": "topology.kubernetes.io/zone",
|
{
|
||||||
"operator": "In",
|
"podResources": {
|
||||||
"values": [
|
"cpuRequest": "200m",
|
||||||
"us-central1-a",
|
"cpuLimit": "400m",
|
||||||
"us-central1-b",
|
"memoryRequest": "200Mi",
|
||||||
"us-central1-c"
|
"memoryLimit": "400Mi"
|
||||||
]
|
},
|
||||||
}
|
"keepLatestMaintenanceJobs": 2
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
EOF
|
EOF
|
||||||
```
|
```
|
||||||
This sample showcases two affinity configurations:
|
This sample showcases two affinity configurations:
|
||||||
@@ -110,7 +126,7 @@ The nodes matching one of the two conditions are selected.
|
|||||||
|
|
||||||
To create the configMap, users need to save something like the above sample to a json file and then run below command:
|
To create the configMap, users need to save something like the above sample to a json file and then run below command:
|
||||||
```
|
```
|
||||||
kubectl create cm repo-maintenance-job-config -n velero --from-file=repo-maintenance-job-config.json
|
kubectl apply -f repo-maintenance-job-config.yaml
|
||||||
```
|
```
|
||||||
|
|
||||||
### Log
|
### Log
|
||||||
|
|||||||
Reference in New Issue
Block a user