Hi I'm trying to create a database with owner ! the owner by default is postgres and I want to change it when a user creates a database
read -p "Enter owner database name : " $owner
read -p "Enter database name : " $my_db
sudo -i -u postgres psql -c 'CREATE DATABASE $my_db OWNER $owner'
I tested this line but it create a database name 'owner '
can someone help me ??