use of io.fabric8.openshift.api.model.operatorhub.v1.OperatorGroupBuilder in project kas-fleetshard by bf2fc6cc711aee1a0c2a.
the class OlmBasedStrimziOperatorManager method installOperatorGroup.
private void installOperatorGroup() {
OperatorGroup operatorGroup = new OperatorGroupBuilder().withNewMetadata().withName(OLM_OPERATOR_GROUP_NAME).withNamespace(namespace).endMetadata().build();
OpenShiftClient client = kubeClient.client().adapt(OpenShiftClient.class);
client.operatorHub().operatorGroups().inNamespace(namespace).createOrReplace(operatorGroup);
}
use of io.fabric8.openshift.api.model.operatorhub.v1.OperatorGroupBuilder in project apicurio-registry by Apicurio.
the class OperatorUtils method createOperatorGroup.
public static OperatorGroup createOperatorGroup(ExtensionContext testContext, String namespace) {
String name = namespace + "-operator-group";
LOGGER.info("Creating operator group {} in namespace {} targeting namespace {}...", name, namespace, namespace);
OperatorGroup operatorGroup = new OperatorGroupBuilder().withNewMetadata().withName(name).withNamespace(namespace).endMetadata().withNewSpec().withTargetNamespaces(namespace).endSpec().build();
ResourceManager.getInstance().createResource(testContext, true, operatorGroup);
return operatorGroup;
}
Aggregations