Search in sources :

Example 21 with SecretKeySelector

use of io.stackgres.common.crd.SecretKeySelector in project stackgres by ongres.

the class ClusterResourceQuarkusTest method getSecretScriptEntry.

private ClusterScriptEntry getSecretScriptEntry() {
    ClusterScriptEntry entry = new ClusterScriptEntry();
    entry.setName("init");
    final ClusterScriptFrom scriptFrom = new ClusterScriptFrom();
    scriptFrom.setSecretScript("CREATE DATABASE test");
    final SecretKeySelector secretMapKeyRef = new SecretKeySelector();
    scriptFrom.setSecretKeyRef(secretMapKeyRef);
    secretMapKeyRef.setKey("script");
    secretMapKeyRef.setName("initScript");
    entry.setScriptFrom(scriptFrom);
    return entry;
}
Also used : ClusterScriptEntry(io.stackgres.apiweb.dto.cluster.ClusterScriptEntry) ClusterScriptFrom(io.stackgres.apiweb.dto.cluster.ClusterScriptFrom) SecretKeySelector(io.stackgres.common.crd.SecretKeySelector)

Aggregations

SecretKeySelector (io.stackgres.common.crd.SecretKeySelector)21 Test (org.junit.jupiter.api.Test)12 StackGresClusterScriptFrom (io.stackgres.common.crd.sgcluster.StackGresClusterScriptFrom)9 StackGresClusterScriptEntry (io.stackgres.common.crd.sgcluster.StackGresClusterScriptEntry)8 StackGresClusterReview (io.stackgres.operator.common.StackGresClusterReview)8 ConstraintValidationTest (io.stackgres.operator.validation.ConstraintValidationTest)8 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)8 ClusterScriptEntry (io.stackgres.apiweb.dto.cluster.ClusterScriptEntry)7 ClusterScriptFrom (io.stackgres.apiweb.dto.cluster.ClusterScriptFrom)7 StackGresClusterInitData (io.stackgres.common.crd.sgcluster.StackGresClusterInitData)5 StackGresClusterSsl (io.stackgres.common.crd.sgcluster.StackGresClusterSsl)5 Secret (io.fabric8.kubernetes.api.model.Secret)4 AwsSecretKeySelector (io.stackgres.common.crd.storages.AwsSecretKeySelector)4 AzureBlobSecretKeySelector (io.stackgres.common.crd.storages.AzureBlobSecretKeySelector)4 BackupStorage (io.stackgres.common.crd.storages.BackupStorage)4 GoogleCloudSecretKeySelector (io.stackgres.common.crd.storages.GoogleCloudSecretKeySelector)4 Metadata (io.stackgres.apiweb.dto.Metadata)3 ConfigMapKeySelector (io.stackgres.common.crd.ConfigMapKeySelector)3 ArgumentMatchers.anyString (org.mockito.ArgumentMatchers.anyString)3 KubernetesClient (io.fabric8.kubernetes.client.KubernetesClient)2