For command line, you can try psql -U homestead -W -h localhost, that will force the password prompt.
If this doesn't work, read on...
You might need to look into whether or not the user can access PostgreSQL under that username from the IP you are logging in from. For this, you need to look into the file /etc/postgresql/9.6/main/pg_hba.conf (keeping in mind that the 9.6 is the version, so your directory name might be something like 9.1 or 9.3). In that file, you'll be looking for a line that looks like this:
host all all 127.0.0.1/32 md5
That line states that the IP address 127.0.0.1 can log in via port mask 32 using md5 password hashing. If you need to log in as homestead from, say, port 12.34.56.78, you would need to add this line underneath:
host all homestead 12.34.56.78/32 md5
After making this adjustment, you need to run pg_ctl reload from the command line for the changes to take effect.
DB_HOST=127.0.0.1 DB_PORT=54320 DB_DATABASE=homestead DB_USERNAME=homestead DB_PASSWORD=secret@CraigRingerpsqlcommand and PostgreSQL's default port is5432. You must have multiple PostgreSQL instances. What if you add-p 54320to your command line?5432, that's why it won't connect. But do you know how to implement postgreSQL in homestead? I can't migrate my database @CraigRingersudo su - postgresconnecting to psql as Os user:psql -wsetting the password to secret for userhomesteadif such user exists and trying again...