Archive old migrations (#426)
* Archive old migrations * Fix invalid placement of migrations
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
DROP TABLE IF EXISTS redirects;
|
||||
|
||||
CREATE TABLE redirects
|
||||
(
|
||||
id SERIAL PRIMARY KEY,
|
||||
market_id INTEGER NOT NULL,
|
||||
source_uri VARCHAR NOT NULL,
|
||||
target_uri VARCHAR NOT NULL,
|
||||
UNIQUE (market_id, source_uri)
|
||||
);
|
||||
|
||||
GRANT ALL ON TABLE redirects TO root;
|
||||
GRANT ALL ON TABLE redirects TO photowall_user;
|
||||
GRANT ALL ON TABLE redirects TO public;
|
||||
|
||||
ALTER TABLE redirects
|
||||
ADD CONSTRAINT market_fkey
|
||||
FOREIGN KEY (market_id)
|
||||
REFERENCES markets(id) MATCH SIMPLE;
|
||||
Reference in New Issue
Block a user