Skip to content

[sled-agent] Self assembling external DNS zone#5059

Merged
karencfv merged 22 commits into
oxidecomputer:mainfrom
karencfv:external-dns-zone
Feb 23, 2024
Merged

[sled-agent] Self assembling external DNS zone#5059
karencfv merged 22 commits into
oxidecomputer:mainfrom
karencfv:external-dns-zone

Conversation

@karencfv

@karencfv karencfv commented Feb 14, 2024

Copy link
Copy Markdown
Contributor

Overview

In addition to implementing the external DNS self assembling zone, this PR contains a new SMF service called opte-interface-setup.

Closes: #2881
Related: #1898

Implementation

This service makes use of the zone-network CLI tool to avoid having too many CLIs doing things.

The CLI is now shipped independently so it can be called by two different services.

The zone-networking opte-interface-set-up command sets up what the ensure_address_for_port() method used to set up.

Justification

The reasoning behind this new service is to avoid setting up too many things via the method_script.sh file, and to avoid code duplication. The Nexus zone will also be using this service to set up the OPTE interface.

@karencfv karencfv marked this pull request as ready for review February 19, 2024 07:54
@karencfv

Copy link
Copy Markdown
Contributor Author

Heya @smklein @citrus-it! Tiny ping to see if I could get a review for this?

@smklein smklein left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work on this! I imagine that the other zones (like Nexus, NTP) exposing an external IP will share similar functionality?

Comment thread illumos-utils/src/lib.rs Outdated
Comment on lines +67 to +69

#[error("Output of [{command}] is empty")]
EmptyOutput { command: String },

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this being used anywhere?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ha! no, I was using it and then I wasn't anymore. Will remove

Comment thread package-manifest.toml
Comment on lines +667 to +684
[package.zone-network-install]
service_name = "zone-network-setup"
only_for_targets.image = "standard"
source.type = "local"
source.paths = [
{ from = "smf/zone-network-setup/manifest.xml", to = "/var/svc/manifest/site/zone-network-setup/manifest.xml" },
]
output.type = "zone"
output.intermediate_only = true

[package.zone-network-setup]
service_name = "zone-network-cli"
only_for_targets.image = "standard"
source.type = "local"
source.rust.binary_names = ["zone-networking"]
source.rust.release = true
output.type = "zone"
output.intermediate_only = true

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why these are two different packages? They seem very tightly coupled

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I separated them since the new opte-interface-setup service uses the CLI as well. It was a bit awkward to have that service use the CLI from another service.

@karencfv

Copy link
Copy Markdown
Contributor Author

I imagine that the other zones (like Nexus, NTP) exposing an external IP will share similar functionality?

Yep! That's why I thought it was best to have a tiny service that did this for those zones now :)

@karencfv karencfv enabled auto-merge (squash) February 22, 2024 22:19
@karencfv karencfv merged commit 2088693 into oxidecomputer:main Feb 23, 2024
@karencfv karencfv deleted the external-dns-zone branch February 23, 2024 08:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert External DNS zone to be self-assembling

2 participants