mirror of
https://github.com/tailscale/tailscale.git
synced 2026-11-21 20:22:41 +09:00
ipn: log PostureChecking in Prefs.Pretty
When prefs gets logged, we weren't recording whether the node had enabled posture checking. Not enabling this is a common cause of device posture failing, so include it here. Updates #cleanup Change-Id: I9e16c9b56ac70f51598172aa717e7e2a33c4fa7c Signed-off-by: Alex Chan <alexc@tailscale.com>
This commit is contained in:
1 parent
31854730c0
commit
5528c3d1ba
2 files changed
+8
No files matched your search
@@ -654,6 +654,9 @@ func (p *Prefs) pretty(goos string) string {
|
||||
if buildfeatures.HasAppConnectors {
|
||||
sb.WriteString(p.AppConnector.Pretty())
|
||||
}
|
||||
if p.PostureChecking {
|
||||
fmt.Fprintf(&sb, "posture=%t ", p.PostureChecking)
|
||||
}
|
||||
if buildfeatures.HasRelayServer && p.RelayServerPort != nil {
|
||||
fmt.Fprintf(&sb, "relayServerPort=%d ", *p.RelayServerPort)
|
||||
}
|
||||
|
||||
@@ -652,6 +652,11 @@ func TestPrefsPretty(t *testing.T) {
|
||||
"linux",
|
||||
`Prefs{ra=false dns=false want=false routes=[] nf=off update=off Persist=nil}`,
|
||||
},
|
||||
{
|
||||
Prefs{PostureChecking: true},
|
||||
"linux",
|
||||
`Prefs{ra=false dns=false want=false routes=[] nf=off update=off posture=true Persist=nil}`,
|
||||
},
|
||||
{
|
||||
Prefs{
|
||||
NetfilterKind: "iptables",
|
||||
|
||||
Reference in new issue
Block a user