I'm still trying to work out how this file creation/deletion thing will work. If I can tag a "&& touch /tmp/pg.trigger" command to the end of the recovery command, how often will that be called? If I can't, I still need to ensure that it is created and deleted before the recovery command is called, otherwise it will see it before it is deleted and put itself online.
Has anyone got a practical example of what they've set up, or know what others have set up?