aboutsummaryrefslogtreecommitdiff
path: root/src/api/admin/api_server.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-05-17 17:16:29 +0200
committerAlex Auvolat <alex@adnab.me>2022-05-17 17:16:29 +0200
commit2ce3513c108a53bdcc5a838704867a4499295d85 (patch)
tree77681eee926bd532a2568dafab899d13691b0e8c /src/api/admin/api_server.rs
parente92c52eb6522a140cdced40bc047149dc638bfa4 (diff)
downloadgarage-2ce3513c108a53bdcc5a838704867a4499295d85.tar.gz
garage-2ce3513c108a53bdcc5a838704867a4499295d85.zip
Specify and implement {Global,Local}{Alias,Unalias}Bucket
Diffstat (limited to 'src/api/admin/api_server.rs')
-rw-r--r--src/api/admin/api_server.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/api/admin/api_server.rs b/src/api/admin/api_server.rs
index 098a54aa..a51d66e5 100644
--- a/src/api/admin/api_server.rs
+++ b/src/api/admin/api_server.rs
@@ -151,6 +151,23 @@ impl ApiHandler for AdminApiServer {
Endpoint::BucketDenyKey => {
handle_bucket_change_key_perm(&self.garage, req, false).await
}
+ // Bucket aliasing
+ Endpoint::GlobalAliasBucket { id, alias } => {
+ handle_global_alias_bucket(&self.garage, id, alias).await
+ }
+ Endpoint::GlobalUnaliasBucket { id, alias } => {
+ handle_global_unalias_bucket(&self.garage, id, alias).await
+ }
+ Endpoint::LocalAliasBucket {
+ id,
+ access_key_id,
+ alias,
+ } => handle_local_alias_bucket(&self.garage, id, access_key_id, alias).await,
+ Endpoint::LocalUnaliasBucket {
+ id,
+ access_key_id,
+ alias,
+ } => handle_local_unalias_bucket(&self.garage, id, access_key_id, alias).await,
}
}
}