-
Notifications
You must be signed in to change notification settings - Fork 50
DB can not be created on a normal namespace in OpenShift (security!) #100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
How can I remove runAsUser property? |
@rbaumgar for openshift envs, you must apply this yaml and specify the service account name "sidb-sa" in the SIDB yaml |
This might be a workaround, but is never a solution. Every normal pod has to run with an arbitrary uid. Sorry, a database is a normal pod and does not require special security requirements. |
Agreed. The latest v1.1.0 has an attribute called setWritePermissions. Set it to false |
does not work on singleinstancedatabase_express.yaml Invalid value: []int64{54321}: 54321 is not an allowed group, provider restricted-v2: .initContainers[0].runAsUser: Invalid value: 54321: must be in the ranges: ...
|
@rbaumgar also set the attribute prebuiltDB to false |
Hi, When I try to apply openshift_rbac.yaml I get the following error:
Installation of the operator went fine:
|
@andbos this works only on OpenShift. Openshift has an SCC object:
|
Yes, started testing in OpenShift.
The instance was installed properly anyway...
No errors in the operator logs. |
Oh, I see. The SCC is completely wrong formated and the api version is wrong. :-( |
@rbaumgar updated the steps to deploy a sidb in a normal namespace/project in openshift . kindly check the PR above |
@IshaanDesai45 I created a new NS oracle. operator.log``` 2024-07-04T08:40:28Z INFO singleinstancedatabase-resource default {"name": "freedb"}
|
The pdb controller is causing this issue. Can you tell me how you are deploying the operator in the namespaced-scope or the cluster-scope |
I am using namespace based installation and added your newly created openshift-rbac. |
BTW it is a bad design when the operator runs with SA |
for using namespace based installation did you also apply the file /rbac/default-ns-rolebinding.yaml with the corresponding namespace ? |
You mean the operator pods that is currently using serviceaccount:oracle-database-operator-sytem:default should use serviceaccount:oracle-database-operator-system: |
yes |
the problem is fixed, typo when applying rbac/default-ns-rolebinding.yaml, therefor I recommended a different approach. |
@rbaumgar we plan to add support of helm charts for the very purpose that user wouldn't need to go and manually change the config/deployment files. So when that is published this your problem of changing the yaml files would be solved |
When I try to deploy the xe-sample to a namespace like "oracle". Operator is not able to create deployment/pod.
runAsUser=54321
is not allowed by default.The text was updated successfully, but these errors were encountered: