Skip to content

Commit

Permalink
internal: use GCR mirror for Docker images
Browse files Browse the repository at this point in the history
  • Loading branch information
jzelinskie committed Apr 11, 2024
1 parent f30c5cb commit 2d43e7a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion internal/datastore/crdb/crdb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ func newCRDBWithUser(t *testing.T, pool *dockertest.Pool) (adminConn *pgx.Conn,
require.NoError(t, rootCertFile.Close())

resource, err := pool.RunWithOptions(&dockertest.RunOptions{
Repository: "cockroachdb/cockroach",
Repository: "mirror.gcr.io/cockroachdb/cockroach",
Tag: testdatastore.CRDBTestVersionTag,
Cmd: []string{"start-single-node", "--certs-dir", "/certs", "--accept-sql-without-tls"},
Mounts: []string{certDir + ":/certs"},
Expand Down
2 changes: 1 addition & 1 deletion internal/testserver/datastore/crdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func RunCRDBForTesting(t testing.TB, bridgeNetworkName string) RunningEngineForT
name := fmt.Sprintf("crds-%s", uuid.New().String())
resource, err := pool.RunWithOptions(&dockertest.RunOptions{
Name: name,
Repository: "cockroachdb/cockroach",
Repository: "mirror.gcr.io/cockroachdb/cockroach",
Tag: CRDBTestVersionTag,
Cmd: []string{"start-single-node", "--insecure", "--max-offset=50ms"},
NetworkID: bridgeNetworkName,
Expand Down
2 changes: 1 addition & 1 deletion internal/testserver/datastore/mysql.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func RunMySQLForTestingWithOptions(t testing.TB, options MySQLTesterOptions, bri
name := fmt.Sprintf("mysql-%s", uuid.New().String())
resource, err := pool.RunWithOptions(&dockertest.RunOptions{
Name: name,
Repository: "mysql",
Repository: "mirror.gcr.io/library/mysql",
Tag: containerImageTag,
Env: []string{"MYSQL_ROOT_PASSWORD=secret"},
// increase max connections (default 151) to accommodate tests using the same docker container
Expand Down
4 changes: 2 additions & 2 deletions internal/testserver/datastore/postgres.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func RunPostgresForTestingWithCommitTimestamps(t testing.TB, bridgeNetworkName s

postgres, err := pool.RunWithOptions(&dockertest.RunOptions{
Name: postgresContainerHostname,
Repository: "postgres",
Repository: "mirror.gcr.io/library/postgres",
Tag: pgVersion,
Env: []string{
"POSTGRES_USER=" + POSTGRES_TEST_USER,
Expand Down Expand Up @@ -173,7 +173,7 @@ func (b *postgresTester) runPgbouncerForTesting(t testing.TB, pool *dockertest.P

pgbouncer, err := pool.RunWithOptions(&dockertest.RunOptions{
Name: pgbouncerContainerHostname,
Repository: "edoburu/pgbouncer",
Repository: "mirror.gcr.io/edoburu/pgbouncer",
Tag: "latest",
Env: []string{
"DB_USER=" + POSTGRES_TEST_USER,
Expand Down

0 comments on commit 2d43e7a

Please sign in to comment.