Closed vimorra closed 1 year ago
To make sure I'm understanding you correctly, you're saying that you have an OPA policy blocking OSM sidecar injection because the osm-init initContainer does not have CPU or memory limits?
we have an Azure Policy Addon with a policy that deny to deploy PODs without limits and requests. From an OSM point of view with the sidecar config in the meshconfig, seems that the config affect only the envoj sidecar and not the osm-init. How is possible to configure the resources also for the osm-init?
This issue will be closed due to a long period of inactivity. If you would like this issue to remain open then please comment or update.
Issue closed due to inactivity.
Bug description: Also if the sidecar resources is defined in the service mesh, than the osm-initi s not configured with this config and this doesn't enable to deploy in a K8S with an OPA policy in limits and request for each POD Affected area (please mark with X where applicable):
Expected behavior: expected behavior is that the limits and request need to apply also to the osm-init and not only to the envoj sidecar. Steps to reproduce the bug (as precisely as possible): Name: poc-app-bbc5645f6.17445f9b5fc40600
Namespace: cis
Labels:
Annotations:
API Version: v1
Count: 7
Event Time:
First Timestamp: 2023-02-16T17:54:42Z
Involved Object:
API Version: apps/v1
Kind: ReplicaSet
Name: poc-app-bbc5645f6
Namespace: cis
Resource Version: 7883160
UID: 54c23b6c-39c7-4395-9ef6-9c013bd994d5
Kind: Event
Last Timestamp: 2023-02-16T17:57:26Z
Message: (combined from similar events): Error creating: pods "poc-app-bbc5645f6-lzg4j" is forbidden: failed quota: mem-cpu-demo: must specify limits.cpu for: osm-init; limits.memory for: osm-init; requests.cpu for: osm-init; requests.memory for: osm-init
Metadata:
Creation Timestamp: 2023-02-16T17:54:42Z
Managed Fields:
API Version: v1
Resource Version: 57118
UID: ebc779a6-0eb2-44be-94b5-6ca0ec58f0e8
Reason: FailedCreate
Reporting Component:
Reporting Instance:
Source:
Component: replicaset-controller
Type: Warning
Events:
Name: osm-mesh-config
Namespace: kube-system
Labels:
Annotations:
API Version: config.openservicemesh.io/v1alpha2
Kind: MeshConfig
Metadata:
Creation Timestamp: 2023-02-10T15:47:40Z
Generation: 4
Managed Fields:
Resource Version: 7882797
UID: a58bbd3f-9174-4653-865d-ca9fc3689444
Spec:
Certificate:
Feature Flags:
Observability:
Sidecar:
Traffic:
Events:
How was OSM installed?: Azure AKS Addon, OSM Version:1.2.3
Anything else we need to know?:
Bug report archive:
Environment:
osm version
): 1.2.3kubectl version
):