Kubernetes' command-line tool is kubectl, while OphenShift uses oc, a typically compatible variant. To support non-OpenShift clusters, the FlexNet Manager Kubernetes Agent's installation script (install.sh) uses kubectl instead of oc. If you’re using oc, the installation script's incompatibility with the oc command will cause the security context constraint template to be missing the following entries.
- allowHostDirVolumePlugin: true
- allowHostIPC: true
- allowHostNetwork: true
- allowHostPID: true
- allowHostPorts: true
- readOnlyRootFilesystem: true
This will result in errors when the SecurityContextConstraints are applied to the cluster:
error: error validating "STDIN": error validating data: [ValidationError(SecurityContextConstraints): missing required field "allowHostDirVolumePlugin" in io.openshift.security.v1.SecurityContextConstraints, ValidationError(SecurityContextConstraints): missing required field "allowHostIPC" in io.openshift.security.v1.SecurityContextConstraints, ValidationError(SecurityContextConstraints): missing required field "allowHostNetwork" in io.openshift.security.v1.SecurityContextConstraints, ValidationError(SecurityContextConstraints): missing required field "allowHostPID" in io.openshift.security.v1.SecurityContextConstraints, ValidationError(SecurityContextConstraints): missing required field "allowHostPorts" in io.openshift.security.v1.SecurityContextConstraints, ValidationError(SecurityContextConstraints): missing required field "readOnlyRootFilesystem" in io.openshift.security.v1.SecurityContextConstraints]; if you choose to ignore these errors, turn validation off with --validate=false
Workarounds
There are two workarounds for the issue.
- Apply the SecurityContextConstraints to the cluster manually using oc:
cd flexera-kubernetes-agents-{version}/krm-{version}/
oc apply -f config/openshift/securitycontextconstraints.yaml
Or
- Instruct the installation script to use oc in place of kubectl:
cd flexera-kubernetes-agents-{version}/krm-{version}/
KUBECTL=oc ./install.sh [options]
Related Articles
Flexera Kubernetes Agent Helm chart error on Openshift: "config::bootstrap: mgsconfig command failed: exec: "mgsconfig": e… 5Number of Views Configure CheckCertificateRevocation and CheckServerCertificate during Flexera Kubernetes Agent Helm chart installation 92Number of Views Enable debug level logging for Flexera Kubernetes Inventory Agent 41Number of Views Fix "ndtrack.exe is not marked for installation" error when installing the FlexNet Inventory Agent on Windows 41Number of Views Inventory received from the Lightweight Kubernetes agent (LWK) fails to import and is not shown on the "All Containers" page 5Number of Views
Hi, I am Reva - Ask me anything.
No new updates
Thanks for the feedback!
Your feedback has been saved.Rate this response:
Add Additional feedback ( Optional )
Are you sure you want to cancel
the case creation?
Are you sure you want to cancel the case creation?
Are you sure you want to close this case
| Products | Region | Phone Numbers |
|---|---|---|
| FlexNet Operations FlexNet Embedded FlexNet Publisher FlexNet Connect FlexNet Code Insight InstallAnywhere InstallShield |
North America * |
+1 630-332-2513 (toll) +1 877-279-2853 (toll-free in North America) |
| Europe * |
+44 1925 944367 (toll) +44 800 047 8642 (toll-free in Europe) |
|
| Japan * | +81 3-4540-5335 (select option 2) | |
| Australia * |
+61 3 9895 2177 +61 1800 560 603 (toll-free in Australia) |
|
|
Usage Intelligence (formerly
Revulytics) Compliance Intelligence |
Please use the Case Portal to submit your support ticket or reach out to your Revenera contact. | |
Case id: 00001065
Activity: Status change: 2 hours ago