Search in sources :

Example 1 with AzureBlobSecretKeySelector

use of io.stackgres.common.crd.storages.AzureBlobSecretKeySelector in project stackgres by ongres.

the class BackupConfigSourceValidatorTest method setAzureBlobCredentials.

private void setAzureBlobCredentials(final BackupConfigReview review, String accountName, String accountKey, String accessKeyName, String accessKeyKey) {
    BackupStorage storage = review.getRequest().getObject().getSpec().getStorage();
    storage.setType("azureblob");
    storage.setAzureBlob(new AzureBlobStorage());
    storage.getAzureBlob().setAzureCredentials(new AzureBlobStorageCredentials());
    storage.getAzureBlob().getAzureCredentials().setSecretKeySelectors(new AzureBlobSecretKeySelector());
    AzureBlobSecretKeySelector azureBlobSecretKeySelector = storage.getAzureBlob().getAzureCredentials().getSecretKeySelectors();
    azureBlobSecretKeySelector.setAccount(new SecretKeySelector(accountKey, accountName));
    azureBlobSecretKeySelector.setAccessKey(new SecretKeySelector(accessKeyKey, accessKeyName));
}
Also used : AzureBlobSecretKeySelector(io.stackgres.common.crd.storages.AzureBlobSecretKeySelector) BackupStorage(io.stackgres.common.crd.storages.BackupStorage) AzureBlobStorageCredentials(io.stackgres.common.crd.storages.AzureBlobStorageCredentials) SecretKeySelector(io.stackgres.common.crd.SecretKeySelector) AzureBlobSecretKeySelector(io.stackgres.common.crd.storages.AzureBlobSecretKeySelector) AwsSecretKeySelector(io.stackgres.common.crd.storages.AwsSecretKeySelector) GoogleCloudSecretKeySelector(io.stackgres.common.crd.storages.GoogleCloudSecretKeySelector) AzureBlobStorage(io.stackgres.common.crd.storages.AzureBlobStorage)

Aggregations

SecretKeySelector (io.stackgres.common.crd.SecretKeySelector)1 AwsSecretKeySelector (io.stackgres.common.crd.storages.AwsSecretKeySelector)1 AzureBlobSecretKeySelector (io.stackgres.common.crd.storages.AzureBlobSecretKeySelector)1 AzureBlobStorage (io.stackgres.common.crd.storages.AzureBlobStorage)1 AzureBlobStorageCredentials (io.stackgres.common.crd.storages.AzureBlobStorageCredentials)1 BackupStorage (io.stackgres.common.crd.storages.BackupStorage)1 GoogleCloudSecretKeySelector (io.stackgres.common.crd.storages.GoogleCloudSecretKeySelector)1