new IP allocator and add postgres to integration tests. (#1756)
This commit is contained in:
parent
f581d4d9c0
commit
384ca03208
119 changed files with 3686 additions and 443 deletions
|
@ -18,12 +18,15 @@ import (
|
|||
"github.com/puzpuzpuz/xsync/v3"
|
||||
"github.com/samber/lo"
|
||||
"golang.org/x/sync/errgroup"
|
||||
"tailscale.com/envknob"
|
||||
)
|
||||
|
||||
const (
|
||||
scenarioHashLength = 6
|
||||
)
|
||||
|
||||
var usePostgresForTest = envknob.Bool("HEADSCALE_INTEGRATION_POSTGRES")
|
||||
|
||||
func enabledVersions(vs map[string]bool) []string {
|
||||
var ret []string
|
||||
for version, enabled := range vs {
|
||||
|
@ -452,6 +455,10 @@ func (s *Scenario) CreateHeadscaleEnv(
|
|||
tsOpts []tsic.Option,
|
||||
opts ...hsic.Option,
|
||||
) error {
|
||||
if usePostgresForTest {
|
||||
opts = append(opts, hsic.WithPostgres())
|
||||
}
|
||||
|
||||
headscale, err := s.Headscale(opts...)
|
||||
if err != nil {
|
||||
return err
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue