OpenSearch failing on openshift environment

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):

OpenSearch- 2.4.X

Describe the issue:
We tried to install OpenSearch on Openshift environment with the help of Helm. and OpenSearch fails to start with other than default namespace.

Configuration:

We followed this link to proceed with installation.

Relevant Logs or Screenshots:
create Pod opensearch-cluster-master-0 in StatefulSet opensearch-cluster-master failed error: pods “opensearch-cluster-master-0” is forbidden: unable to validate against any security context constraint: [provider “anyuid”: Forbidden: not usable by user or serviceaccount, provider “dynatrace-dynakube-oneagent-unprivileged”: Forbidden: not usable by user or serviceaccount, provider “dynatrace-dynakube-oneagent-privileged”: Forbidden: not usable by user or serviceaccount, provider restricted: .spec.securityContext.fsGroup: Invalid value: int64{1000}: 1000 is not an allowed group, spec.initContainers[0].securityContext.runAsUser: Invalid value: 0: must be in the ranges: [1000670000, 1000679999], spec.containers[0].securityContext.runAsUser: Invalid value: 1000: must be in the ranges: [1000670000, 1000679999], provider “nonroot”: Forbidden: not usable by user or serviceaccount, provider “hostmount-anyuid”: Forbidden: not usable by user or serviceaccount, provider “machine-api-termination-handler”: Forbidden: not usable by user or serviceaccount, provider “hostnetwork”: Forbidden: not usable by user or serviceaccount, provider “hostaccess”: Forbidden: not usable by user or serviceaccount, provider “twistlock-scc”: Forbidden: not usable by user or serviceaccount, provider “node-exporter”: Forbidden: not usable by user or serviceaccount, provider “privileged”: Forbidden: not usable by user or serviceaccount]

We’re currently using Dashboards on Openshift, the problem mostly lies with the Openshift security context.
It seems your Openshift cluster doesn’t allow for user “1000”, which is the user opensearch defaults permissions to.
AFAIK, this isn’t typical behavior, and might be defined by your Openshift administrator.
Try asking them to allow user “1000”,or alternatively, allow root user in your namespace (user 0)

I am able to get pods up in openshift after assigning the additional privileges using:

oc adm policy add-scc-to-user privileged -z default