Hi Guys
Does anyone know what i am doing wrong to create my sidecar ?
I am new in kubernetes and I am trying to create a sidecar called “claro-noc-sidecar-gatewayproxy-n7” but, after i execute “oc replace filename”, this sidecard is not created.
Bellow is my yaml file:
apiVersion: apps/v1
kind: Deployment
metadata:
annotations:
deployment.kubernetes.io/revision: "6"
meta.helm.sh/release-name: openet-sm-pcf
meta.helm.sh/release-namespace: openet-sm-pcf
creationTimestamp: "2023-07-25T02:05:13Z"
generation: 7
labels:
app: gloo
app.kubernetes.io/managed-by: Helm
gateway-proxy-id: gateway-proxy
gloo: gateway-proxy
name: gateway-proxy
namespace: openet-sm-pcf
spec:
progressDeadlineSeconds: 600
replicas: 2
revisionHistoryLimit: 10
selector:
matchLabels:
gateway-proxy-id: gateway-proxy
gloo: gateway-proxy
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
annotations:
kubectl.kubernetes.io/restartedAt: "2023-08-23T18:13:40-03:00"
nf-service-types: |
- npcf-am-policy-control
- npcf-ue-policy-control
prometheus.io/path: /metrics
prometheus.io/port: "8081"
prometheus.io/scrape: "true"
sidecar.istio.io/inject: "false"
labels:
gateway-proxy: live
gateway-proxy-id: gateway-proxy
gloo: gateway-proxy
nf-instance-id: f941aef9-636a-4f14-bcad-b18f15a9a0ce
nf-type: PCF
spec:
containers:
- image: claudioract/claro-sidecar-openet-5gsa:1.0
imagePullPolicy: Always
name: claro-noc-sidecar-gatewayproxy-n7
resources: {}
securityContext:
allowPrivilegeEscalation: true
capabilities:
add:
- NET_RAW
- NET_ADMIN
- SYS_ADMIN
- NET_BIND_SERVICE
drop:
- ALL
privileged: true
runAsNonRoot: false
- args:
- --disable-hot-restart
env:
- name: POD_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
- name: POD_NAME
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.name
image: dependencies.openet.com:5000/solo-io/gloo-envoy-wrapper:1.10.45
imagePullPolicy: IfNotPresent
name: gateway-proxy
ports:
- containerPort: 8080
name: http
protocol: TCP
- containerPort: 8443
name: https
protocol: TCP
resources:
limits:
cpu: "2"
memory: 6G
requests:
cpu: "2"
memory: 6G
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
runAsNonRoot: true
runAsUser: 10101
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /etc/envoy
name: envoy-config
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
securityContext:
fsGroup: 10101
runAsUser: 10101
serviceAccount: gateway-proxy
serviceAccountName: gateway-proxy
terminationGracePeriodSeconds: 30
volumes:
- configMap:
defaultMode: 420
name: gateway-proxy-envoy-config
name: envoy-config
status:
availableReplicas: 2
conditions:
- lastTransitionTime: "2023-07-25T02:05:32Z"
lastUpdateTime: "2023-07-25T02:05:32Z"
message: Deployment has minimum availability.
reason: MinimumReplicasAvailable
status: "True"
type: Available
- lastTransitionTime: "2023-07-25T02:05:13Z"
lastUpdateTime: "2023-08-23T21:13:47Z"
message: ReplicaSet "gateway-proxy-5d9f46b8d6" has successfully progressed.
reason: NewReplicaSetAvailable
status: "True"
type: Progressing
observedGeneration: 7
readyReplicas: 2
replicas: 2
updatedReplicas: 2
i have only modified a pre existent deploy yaml file above, adding this 3 lines bellow, but the sidecar is not created (only pod called “gateway-proxy” is created)
- image: claudioract/claro-sidecar-openet-5gsa:1.0
imagePullPolicy: Always
name: claro-noc-sidecar-gatewayproxy-n7