init
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: pod-already-has-sidecar
|
||||
namespace: default
|
||||
annotations:
|
||||
logging.company.com/enabled: "true"
|
||||
spec:
|
||||
containers:
|
||||
- name: app
|
||||
image: nginx:1.25.3
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
- name: fluent-bit # sidecar уже есть — injection не сработает
|
||||
image: fluent/fluent-bit:2.1
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
14
03-mutation/02-sidecar/test-resources/pod-no-logging.yaml
Normal file
14
03-mutation/02-sidecar/test-resources/pod-no-logging.yaml
Normal file
@@ -0,0 +1,14 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: pod-no-logging
|
||||
namespace: default
|
||||
# нет аннотации logging.company.com/enabled — sidecar не добавится
|
||||
spec:
|
||||
containers:
|
||||
- name: app
|
||||
image: nginx:1.25.3
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
15
03-mutation/02-sidecar/test-resources/pod-with-logging.yaml
Normal file
15
03-mutation/02-sidecar/test-resources/pod-with-logging.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: pod-with-logging
|
||||
namespace: default
|
||||
annotations:
|
||||
logging.company.com/enabled: "true" # триггер для injection
|
||||
spec:
|
||||
containers:
|
||||
- name: app
|
||||
image: nginx:1.25.3
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
@@ -0,0 +1,16 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: pod-with-monitoring
|
||||
namespace: default
|
||||
annotations:
|
||||
monitoring.company.com/scrape: "true"
|
||||
monitoring.company.com/port: "8080" # кастомный порт scraping
|
||||
spec:
|
||||
containers:
|
||||
- name: app
|
||||
image: nginx:1.25.3
|
||||
resources:
|
||||
limits:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
Reference in New Issue
Block a user