Debug Container
ΠΠ°ΠΏΡΡΠΊ debug containerβΠ° Π² K8S
kubectl run tmp-shell --rm -i --tty --image nicolaka/netshoot -- /bin/bash
apiVersion: apps/v1
kind: Deployment
metadata:
name: debug-deployment
labels:
app: debug
spec:
replicas: 1
selector:
matchLabels:
app: debug
template:
metadata:
labels:
app: debug
spec:
containers:
- name: debug-container
image: nicolaka/netshoot:latest
command: [ "/bin/bash", "-c", "--" ]
args: [ "while true; do sleep 3000; done;" ]
resources:
limits:
cpu: "500m" # ΠΠΈΠΌΠΈΡ CPU - 0.5 ΡΠ΄ΡΠ°
memory: "512Mi" # ΠΠΈΠΌΠΈΡ ΠΏΠ°ΠΌΡΡΠΈ - 512 ΠΌΠ΅Π³Π°Π±Π°ΠΉΡ
requests:
cpu: "100m" # ΠΠ°ΠΏΡΠ°ΡΠΈΠ²Π°Π΅ΠΌΡΠΉ CPU - 0.1 ΡΠ΄ΡΠ°
memory: "128Mi" # ΠΠ°ΠΏΡΠ°ΡΠΈΠ²Π°Π΅ΠΌΠ°Ρ ΠΏΠ°ΠΌΡΡΡ - 128 ΠΌΠ΅Π³Π°Π±Π°ΠΉΡ
# ΠΡΠΈΠΌΠ΅ΡΠ°Π½ΠΈΠ΅: Π·Π½Π°ΡΠ΅Π½ΠΈΡ ΠΌΠΎΠ³ΡΡ Π±ΡΡΡ ΡΠΊΠΎΡΡΠ΅ΠΊΡΠΈΡΠΎΠ²Π°Π½Ρ Π² Π·Π°Π²ΠΈΡΠΈΠΌΠΎΡΡΠΈ ΠΎΡ Π²Π°ΡΠΈΡ
ΠΏΠΎΡΡΠ΅Π±Π½ΠΎΡΡΠ΅ΠΉ ΠΈ ΠΏΠΎΠ»ΠΈΡΠΈΠΊ ΠΊΠ»Π°ΡΡΠ΅ΡΠ°.