Skip to content

Commit

Permalink
Update restore-resource-modifiers.md
Browse files Browse the repository at this point in the history
  • Loading branch information
anshulahuja98 authored Aug 2, 2023
1 parent 51eaad6 commit c2c5b7b
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions site/content/docs/main/restore-resource-modifiers.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Q---
---
title: "Restore Resource Modifiers"
layout: docs
---
Expand All @@ -25,7 +25,7 @@ Below is the two-step of using resource modifiers to modify the resources during
**YAML template**

- Yaml template:
```yaml
```yaml
version: v1
resourceModifierRules:
- conditions:
Expand All @@ -34,12 +34,12 @@ resourceModifierRules:
namespaces:
- bar
- foo
patches:
- operation: replace
path: "/spec/storageClassName"
value: "premium"
- operation: remove
path: "/metadata/labels/test"
patches:
- operation: replace
path: "/spec/storageClassName"
value: "premium"
- operation: remove
path: "/metadata/labels/test"
```

- The above configmap will apply the JSON Patch to all the PVCs in the namespaces bar and foo with name starting with mysql. The JSON Patch will replace the storageClassName with "premium" and remove the label "test" from the PVCs.
Expand Down

0 comments on commit c2c5b7b

Please sign in to comment.