Skip to content

fix(coderd): pass block endpoints into servertailnet #12149

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 8, 2024

Conversation

coadler
Copy link
Contributor

@coadler coadler commented Feb 15, 2024

No description provided.

Copy link
Contributor Author

coadler commented Feb 15, 2024

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @coadler and the rest of your teammates on Graphite Graphite

@coadler coadler force-pushed the colin/fixcoderdpassblockendpointsintoservertailnet branch 3 times, most recently from cc569a7 to 26107fc Compare February 15, 2024 00:46
@coadler coadler requested a review from spikecurtis February 15, 2024 01:19
@@ -163,6 +165,12 @@ func NewServerTailnet(
return tn, nil
}

// Conn is used to access the underlying tailnet conn of the ServerTailnet. It
// should only be used for read-only purposes.
Copy link
Contributor

Choose a reason for hiding this comment

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

Adding this plus the multiple levels of Get methods seems like a lot just to test that we successfully set a flag.

Can we call the coordinator.Node() method and directly verify that endpoints are not set?

Copy link
Contributor Author

@coadler coadler Feb 15, 2024

Choose a reason for hiding this comment

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

Yeah, that's definitely true. What I was trying to get at was to only test the specific logic of the servertailnet, which is only responsible for setting the two fields on the configmap and nodeupdater. By checking the node I'm essentially testing logic in tailnet, but that might be a fair tradeoff.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The more I think about this I'm not sure that checking the endpoints is a solid way to go, since it seems very racey. How do I know that the agent just hasn't finished the STUN dance before I check? Should I just wait x seconds and verify that we never get a STUN addr?

Copy link
Contributor

Choose a reason for hiding this comment

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

Don't want racy tests! If this plumbing is the cost, then so be it, I guess.

@coadler coadler force-pushed the colin/fixcoderdpassblockendpointsintoservertailnet branch 2 times, most recently from b8bc41d to 52a7f86 Compare February 15, 2024 23:49
@github-actions github-actions bot added stale This issue is like stale bread. and removed stale This issue is like stale bread. labels Feb 23, 2024
@github-actions github-actions bot added the stale This issue is like stale bread. label Mar 3, 2024
@github-actions github-actions bot closed this Mar 7, 2024
@spikecurtis spikecurtis reopened this Mar 7, 2024
@spikecurtis
Copy link
Contributor

@coadler we still want this one, right?

@coadler coadler removed the stale This issue is like stale bread. label Mar 7, 2024
@coadler coadler force-pushed the colin/fixcoderdpassblockendpointsintoservertailnet branch from 52a7f86 to fac774b Compare March 8, 2024 05:18
@coadler coadler enabled auto-merge (squash) March 8, 2024 05:20
@coadler coadler merged commit 66154f9 into main Mar 8, 2024
@coadler coadler deleted the colin/fixcoderdpassblockendpointsintoservertailnet branch March 8, 2024 05:29
@github-actions github-actions bot locked and limited conversation to collaborators Mar 8, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants