Spaces:
Runtime error
Runtime error
File size: 730 Bytes
0ddcb86 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | -- Initialize PostgreSQL database with proper permissions
-- This script sets up the rasta_ai database and grants necessary privileges
-- Ensure the user has all privileges on the database
GRANT ALL PRIVILEGES ON DATABASE rasta_ai TO rasta;
-- Connect to the database and grant schema permissions
\c rasta_ai
-- Grant all privileges on the public schema
GRANT ALL ON SCHEMA public TO rasta;
-- Make rasta the owner of future objects in public schema
ALTER DEFAULT PRIVILEGES FOR USER postgres IN SCHEMA public GRANT ALL ON TABLES TO rasta;
ALTER DEFAULT PRIVILEGES FOR USER postgres IN SCHEMA public GRANT ALL ON SEQUENCES TO rasta;
ALTER DEFAULT PRIVILEGES FOR USER postgres IN SCHEMA public GRANT ALL ON FUNCTIONS TO rasta;
|