public static S3Client Create() { //Public minio playground credentials StringAccessKey key = new StringAccessKey("Q3AM3UQ867SPQQA43P2F", "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG"); //Minio expect the region to always be USEast1 S3Config config = new S3Config(key, AwsRegion.UsEast1); //We have to set the endpoint to point to the Minio Playground server config.Endpoint = new Uri("https://play.min.io:9000/"); return(new S3Client(config)); }
private void ConfigureS3(S3Config config) { //Set the configuration from the config file _configRoot.Bind(config); StringAccessKey secret = new StringAccessKey(_configRoot[nameof(StringAccessKey.KeyId)], _configRoot[nameof(StringAccessKey.AccessKey)]); if (string.IsNullOrWhiteSpace(secret.KeyId)) { throw new Exception("Did you forget to set a KeyId? See Readme.txt on how to run live tests"); } if (secret.AccessKey == null) { throw new Exception("Did you forget to set a secret key? See Readme.txt on how to run live tests"); } config.Credentials = secret; }