aboutsummaryrefslogtreecommitdiff
path: root/src/k2v-client/bin
diff options
context:
space:
mode:
Diffstat (limited to 'src/k2v-client/bin')
-rw-r--r--src/k2v-client/bin/k2v-cli.rs15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/k2v-client/bin/k2v-cli.rs b/src/k2v-client/bin/k2v-cli.rs
index 984b4192..5a2422ab 100644
--- a/src/k2v-client/bin/k2v-cli.rs
+++ b/src/k2v-client/bin/k2v-cli.rs
@@ -8,9 +8,6 @@ use k2v_client::*;
use format_table::format_table;
-use rusoto_core::credential::AwsCredentials;
-use rusoto_core::Region;
-
use clap::{Parser, Subcommand};
/// K2V command line interface
@@ -408,14 +405,16 @@ async fn main() -> Result<(), Error> {
let args = Args::parse();
- let region = Region::Custom {
- name: args.region,
+ let config = K2vClientConfig {
endpoint: args.endpoint,
+ region: args.region,
+ aws_access_key_id: args.key_id,
+ aws_secret_access_key: args.secret,
+ bucket: args.bucket,
+ user_agent: None,
};
- let creds = AwsCredentials::new(args.key_id, args.secret, None, None);
-
- let client = K2vClient::new(region, args.bucket, creds, None)?;
+ let client = K2vClient::new(config)?;
match args.command {
Command::Insert {