-- 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;