Port from env and isRunning on first startup

Consult $PGPORT when setting port, with this our reported port follows the same precedence as the one used by postgres: postgresql.conf -> $PGPORT -> default port (5432).

Set isRunning when Postgres is started the first time and need to setup the database. This was missing and in applicationShouldTerminate can wrongly bypass the shutdown code so a running postgres server is not stopped.

Removed the attempt to restart the server if startup failed. Since we use -w and get proper exist status back, we know if startup failed and if it failed there is no reason to think it will work immediately again.