Skip to content

Commit

Permalink
Start dpd with Nexus-provided listen address
Browse files Browse the repository at this point in the history
  • Loading branch information
bnaecker committed Aug 8, 2022
1 parent 63315ba commit 1d634ce
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package-manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -148,5 +148,5 @@ zone = true
# 3. Use type = "manual" instead of the "prebuilt"
type = "prebuilt"
repo = "dendrite"
commit = "e752af977c167fa64625231a74bedcbfa5457008"
sha256 = "ddb7c271f4d4b68332adc69b32f90e728f07b1395e01cffd7e71230c2c648c63"
commit = "d76d206b93d0126eae973490a6d38df868bcbe27"
sha256 = "e4cebf6a68b8640f1af1a66fe32b15f87917aea335ccda440ead92ea515e3757"
20 changes: 20 additions & 0 deletions sled-agent/src/services.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ use crate::illumos::zone::AddressRequest;
use crate::params::{ServiceEnsureBody, ServiceRequest, ServiceType};
use crate::zone::Zones;
use omicron_common::address::Ipv6Subnet;
use omicron_common::address::DENDRITE_PORT;
use omicron_common::address::NEXUS_INTERNAL_PORT;
use omicron_common::address::OXIMETER_PORT;
use omicron_common::address::RACK_PREFIX;
Expand Down Expand Up @@ -579,6 +580,8 @@ impl ServiceManager {
}
ServiceType::Dendrite { asic } => {
info!(self.log, "Setting up dendrite service");

let address = service.addresses[0];
running_zone
.run_cmd(&[
crate::illumos::zone::SVCCFG,
Expand All @@ -592,6 +595,23 @@ impl ServiceManager {
err,
})?;

running_zone
.run_cmd(&[
crate::illumos::zone::SVCCFG,
"-s",
&smf_name,
"setprop",
&format!(
"config/address=[{}]:{}",
address, DENDRITE_PORT,
),
])
.map_err(|err| Error::ZoneCommand {
intent: "set dendrite API server listen address"
.to_string(),
err,
})?;

running_zone
.run_cmd(&[
crate::illumos::zone::SVCCFG,
Expand Down

0 comments on commit 1d634ce

Please sign in to comment.