Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jenner\Crontab\Mission运行前未设置要运行的用户组以及用户 #2

Closed
longhua828 opened this issue Feb 12, 2016 · 1 comment

Comments

@longhua828
Copy link

修改如下,不知道合适不合适

   /**
     * start mission process
     */
    public function run()
    {
        // set user and group
        $this->setUserAndGroup();
        $out = $this->out;
        $err = $this->err;
        $process = new \Symfony\Component\Process\Process($this->cmd);
        $process->run(function ($type, $buffer) use ($out, $err) {
            if ($type == \Symfony\Component\Process\Process::ERR) {
                $err->error($buffer);
            } else {
                $out->info($buffer);
            }
        });
    }
@white-poto
Copy link
Owner

已修复

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants