Fix source remote migration markers
Authored by
mfwolffe <wolffemf@dukes.jmu.edu>
- SHA
7f1654edba5beb48550b585b8d8a7230c07935ba- Parents
-
2daad21 - Tree
e7b6797
7f1654e
7f1654edba5beb48550b585b8d8a7230c07935ba2daad21
e7b6797| Status | File | + | - |
|---|---|---|---|
| M |
internal/migrationsfs/migrations/0052_repo_source_remotes.sql
|
13 | 0 |
internal/migrationsfs/migrations/0052_repo_source_remotes.sqlmodified@@ -1,4 +1,11 @@ | ||
| 1 | 1 | -- SPDX-License-Identifier: AGPL-3.0-or-later |
| 2 | +-- | |
| 3 | +-- Durable public source remotes for repo imports and submodule gitlink | |
| 4 | +-- hydration. A repo may remember one upstream fetch URL; fetch status is | |
| 5 | +-- advisory so failed imports can be retried from settings without losing | |
| 6 | +-- the configured remote. | |
| 7 | + | |
| 8 | +-- +goose Up | |
| 2 | 9 | |
| 3 | 10 | CREATE TABLE repo_source_remotes ( |
| 4 | 11 | repo_id bigint PRIMARY KEY REFERENCES repos(id) ON DELETE CASCADE, |
@@ -14,3 +21,9 @@ CREATE TABLE repo_source_remotes ( | ||
| 14 | 21 | CREATE TRIGGER repo_source_remotes_set_updated_at |
| 15 | 22 | BEFORE UPDATE ON repo_source_remotes |
| 16 | 23 | FOR EACH ROW EXECUTE FUNCTION tg_set_updated_at(); |
| 24 | + | |
| 25 | + | |
| 26 | +-- +goose Down | |
| 27 | + | |
| 28 | +DROP TRIGGER IF EXISTS repo_source_remotes_set_updated_at ON repo_source_remotes; | |
| 29 | +DROP TABLE IF EXISTS repo_source_remotes; | |