mirror of
https://github.com/juanfont/headscale.git
synced 2025-08-11 18:07:33 +00:00
policy/v2: make default (#2546)
* policy/v2: make default Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> * integration: do not run v1 tests Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> * policy/v2: fix potential nil pointers Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> * mapper: fix test failures in v2 Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> --------- Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
This commit is contained in:
@@ -70,7 +70,6 @@ type HeadscaleInContainer struct {
|
||||
tlsKey []byte
|
||||
filesInContainer []fileInContainer
|
||||
postgres bool
|
||||
policyV2 bool
|
||||
policyMode types.PolicyMode
|
||||
}
|
||||
|
||||
@@ -188,11 +187,10 @@ func WithPostgres() Option {
|
||||
}
|
||||
}
|
||||
|
||||
// WithPolicyV2 tells the integration test to use the new v2 filter.
|
||||
func WithPolicyV2() Option {
|
||||
// WithPolicyV1 tells the integration test to use the old v1 filter.
|
||||
func WithPolicyV1() Option {
|
||||
return func(hsic *HeadscaleInContainer) {
|
||||
hsic.policyV2 = true
|
||||
hsic.env["HEADSCALE_EXPERIMENTAL_POLICY_V2"] = "1"
|
||||
hsic.env["HEADSCALE_POLICY_V1"] = "1"
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user