Skip to content

Commit

Permalink
Looks like we need OPTE_IP
Browse files Browse the repository at this point in the history
  • Loading branch information
karencfv committed Feb 14, 2024
1 parent a11cce7 commit 62ea894
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sled-agent/src/services.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1899,7 +1899,7 @@ impl ServiceManager {
)?;

let http_addr = format!("[{}]:{}", static_addr, DNS_HTTP_PORT);
let dns_addr = format!("{}:{}", opte_gateway, DNS_PORT);
let dns_addr = format!("{}", DNS_PORT);

let external_dns_config = PropertyGroupBuilder::new("config")
// TODO: Removeme and move to new opte interface service
Expand Down
3 changes: 2 additions & 1 deletion smf/external-dns/method_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ OPTE_INTERFACE="$(svcprop -c -p config/opte_interface "${SMF_FMRI}")"
OPTE_GATEWAY="$(svcprop -c -p config/opte_gateway "${SMF_FMRI}")"

HTTP_ADDR="$(svcprop -c -p config/http_address "${SMF_FMRI}")"
# TODO: Rename DNS_ADDR to DNS_PORT if I don't find a way to retrieve OPTE_IP from the installed zone somehow
DNS_ADDR="$(svcprop -c -p config/dns_address "${SMF_FMRI}")"

# TODO: This should be its own service
Expand All @@ -31,7 +32,7 @@ fi
args=(
"--config-file" "/var/svc/manifest/site/external_dns/config.toml"
"--http-address" "$HTTP_ADDR"
"--dns-address" "$DNS_ADDR"
"--dns-address" "$OPTE_IP:$DNS_ADDR"
)

exec /opt/oxide/dns-server/bin/dns-server "${args[@]}" &

0 comments on commit 62ea894

Please sign in to comment.