The pg_dump command was using the incorrect switch -d (dbname) instead of -h (hostname) and did not specify the login username with -U switch.
The psql command did not specify the login username with -U switch.
Once I corrected the commands as per this edit, I was able to migrate successfully from one project to another