Skip to content

Commit c0b0acf

Browse files
committed
roachtest: fix network/authentication pgurl
This test uses a pgurl as part of a shell command, so it needs to be escaped to avoid any stray ampersands.
1 parent 060cbd4 commit c0b0acf

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

pkg/cmd/roachtest/tests/network.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,6 @@ func runNetworkAuthentication(ctx context.Context, t test.Test, c cluster.Cluste
8585
c.Start(ctx, t.L(), startOpts, settings, c.Node(1))
8686
}
8787

88-
t.L().Printf("retrieving server addresses...")
89-
serverUrls, err := c.InternalPGUrl(ctx, t.L(), serverNodes, roachprod.PGURLOptions{Auth: install.AuthUserPassword})
90-
require.NoError(t, err)
91-
9288
t.L().Printf("fetching certs...")
9389
certsDir := fmt.Sprintf("/home/ubuntu/%s", install.CockroachNodeCertsDir)
9490
localCertsDir, err := filepath.Abs("./network-certs")
@@ -206,7 +202,7 @@ SELECT $1::INT = ALL (
206202
}
207203

208204
// Construct a connection URL to server i.
209-
url := serverUrls[server-1]
205+
url := fmt.Sprintf("{pgurl:%d}", server)
210206

211207
// Attempt a client connection to that server.
212208
t.L().Printf("server %d, attempt %d; url: %s\n", server, attempt, url)

0 commit comments

Comments
 (0)