Skip to content

Commit

Permalink
Merged PR 860636: Update edgeHub identity
Browse files Browse the repository at this point in the history
This is a temporary fix to update edgeHub identity. To be removed when agent can update identities.
  • Loading branch information
ancaantochi authored and myagley committed May 25, 2018
1 parent 353e36a commit 865ad58
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion edgelet/edgelet-core/src/watchdog.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ where
let name = spec.name().to_string();

// Update identity of EdgeAgent to use the Auth mechanism supported by this Edgelet (Sas tokens)
update_identity(&mut self.id_mgr, module_id)
let mut id_mgr_copy = self.id_mgr.clone();
let module_id = module_id.to_string();
//TODO: remove edgeHub identity update when agent can update identities
update_identity(&mut self.id_mgr, "$edgeHub")
.and_then(move |_| update_identity(&mut id_mgr_copy, &module_id))
.and_then(move |id| runtime.list().map(|m| (id, m)).map_err(|e| e.into()))
.and_then(move |(id, m)| {
m.iter()
Expand Down

0 comments on commit 865ad58

Please sign in to comment.