func (c *Controller) ExitStatus() <-chan error {
	return c.doneCh
}
ExitStatus returns a chanel through which the exit status is returned when NGINX exits.
package nginx
import (
	"bytes"
	"fmt"
	"os"
	"os/exec"
	"text/template"
	"github.com/golang/glog"
)
type Controller struct {
	doneCh  chan error
	started bool
}
func NewController() *Controller {
	return &Controller{
		doneCh: make(chan error),
	}
}
func (c *Controller) start() error {
	cmd := exec.Command("nginx", "-g", "daemon off;", "-c", "/etc/istio/proxy/nginx.conf")
	cmd.Stdout = os.Stdout
	cmd.Stderr = os.Stderr
	if err := cmd.Start(); err != nil {
		return fmt.Errorf("failed to start NGINX: %v", err)
	}
	go func() {
		c.doneCh <- cmd.Wait()
		close(c.doneCh)
	}()
	return nil
}