use of io.stackgres.common.crd.sgcluster.StackGresClusterScriptEntry in project stackgres by ongres.
the class ClusterRequiredResourcesGenerator method getPostgresExporterInitScript.
private StackGresClusterScriptEntry getPostgresExporterInitScript() {
final StackGresClusterScriptEntry script = new StackGresClusterScriptEntry();
script.setName("prometheus-postgres-exporter-init");
script.setDatabase("postgres");
script.setScript(Unchecked.supplier(() -> Resources.asCharSource(ClusterRequiredResourcesGenerator.class.getResource("/prometheus-postgres-exporter/init.sql"), StandardCharsets.UTF_8).read()).get());
return script;
}
Aggregations