Add a - between the su and postgres so that we inherit the Postgres user's environment and don't try to run the command with /root as the working directory.