migrations: add index on units.v1path_id

Change-Id: Ic4611f62209bf324c9987b9626a6ed200d93bd19
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/283645
Trust: Julie Qiu <julie@golang.org>
Run-TryBot: Julie Qiu <julie@golang.org>
TryBot-Result: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jonathan Amsterdam <jba@google.com>
diff --git a/migrations/000057_add_idx_units_v1path_id.down.sql b/migrations/000057_add_idx_units_v1path_id.down.sql
new file mode 100644
index 0000000..6a780fd
--- /dev/null
+++ b/migrations/000057_add_idx_units_v1path_id.down.sql
@@ -0,0 +1,9 @@
+-- Copyright 2021 The Go Authors. All rights reserved.
+-- Use of this source code is governed by a BSD-style
+-- license that can be found in the LICENSE file.
+
+BEGIN;
+
+DROP INDEX idx_units_v1path_id;
+
+END;
diff --git a/migrations/000057_add_idx_units_v1path_id.up.sql b/migrations/000057_add_idx_units_v1path_id.up.sql
new file mode 100644
index 0000000..6db6546
--- /dev/null
+++ b/migrations/000057_add_idx_units_v1path_id.up.sql
@@ -0,0 +1,5 @@
+-- Copyright 2021 The Go Authors. All rights reserved.
+-- Use of this source code is governed by a BSD-style
+-- license that can be found in the LICENSE file.
+
+CREATE INDEX CONCURRENTLY idx_units_v1path_id ON units(v1path_id);