diff --git a/examples/customresourceinterpreter/workload-propagationpolicy.yaml b/examples/customresourceinterpreter/workload-propagationpolicy.yaml new file mode 100644 index 000000000000..56baa6b8f6e6 --- /dev/null +++ b/examples/customresourceinterpreter/workload-propagationpolicy.yaml @@ -0,0 +1,27 @@ +apiVersion: policy.karmada.io/v1alpha1 +kind: PropagationPolicy +metadata: + name: nginx-workload-propagation +spec: + resourceSelectors: + - apiVersion: workload.example.io/v1alpha1 + kind: Workload + name: nginx + placement: + clusterAffinity: + clusterNames: + - member1 + - member2 + replicaScheduling: + replicaDivisionPreference: Weighted + replicaSchedulingType: Divided + weightPreference: + staticWeightList: + - targetCluster: + clusterNames: + - member1 + weight: 2 + - targetCluster: + clusterNames: + - member2 + weight: 1 diff --git a/examples/customresourceinterpreter/workload.yaml b/examples/customresourceinterpreter/workload.yaml new file mode 100644 index 000000000000..b86d37707887 --- /dev/null +++ b/examples/customresourceinterpreter/workload.yaml @@ -0,0 +1,16 @@ +apiVersion: workload.example.io/v1alpha1 +kind: Workload +metadata: + name: nginx + labels: + app: nginx +spec: + replicas: 3 + template: + metadata: + labels: + app: nginx + spec: + containers: + - image: nginx + name: nginx