SED_PG_CONF: fix race condition that corrupted configurations
SED_PG_CONF: fix race condition that corrupted configurations

The following pipeline:

    $CAT $SED_TMP_FILE | $TRUSTED_SHELL ${SED_HOST} $DD of=$SED_TMP_FILE > /dev/null 2>&1

when run with a TRUSTED_SHELL that executed the command on the local
host, suffered from a race where cat was reading from the file as dd was
attempting to truncate it. In situations where dd won that race, the
resulting sed command file would be empty, and no change would be made.

Simplify the logic by removing all temporary files, and forwarding the
sed command file contents to TRUSTED_SHELL via the stdin pipe.

Co-authored-by: Shoaib Lari <ad045e028025f2970ed8506438710c2da1df61d5@pivotal.io>

ashwinstar/gpdb,lisakowen/gpdb,adam8157/gpdb,50wu/gpdb,greenplum-db/gpdb,50wu/gpdb,50wu/gpdb,greenplum-db/gpdb,adam8157/gpdb,greenplum-db/gpdb,ashwinstar/gpdb,jmcatamney/gpdb,ashwinstar/gpdb,xinzweb/gpdb,adam8157/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,ashwinstar/gpdb,xinzweb/gpdb,lisakowen/gpdb,50wu/gpdb,adam8157/gpdb,50wu/gpdb,50wu/gpdb,adam8157/gpdb,xinzweb/gpdb,jmcatamney/gpdb,jmcatamney/gpdb,xinzweb/gpdb,lisakowen/gpdb,jmcatamney/gpdb,xinzweb/gpdb,xinzweb/gpdb,50wu/gpdb,xinzweb/gpdb,lisakowen/gpdb,adam8157/gpdb,lisakowen/gpdb,50wu/gpdb,jmcatamney/gpdb,lisakowen/gpdb,xinzweb/gpdb,ashwinstar/gpdb,greenplum-db/gpdb,ashwinstar/gpdb,jmcatamney/gpdb,greenplum-db/gpdb,adam8157/gpdb,greenplum-db/gpdb,ashwinstar/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,adam8157/gpdb,ashwinstar/gpdb,lisakowen/gpdb,lisakowen/gpdb