[Fuego] [PATCH] ftc: add user_check for when ftc is executed as root

Tim.Bird at sony.com Tim.Bird at sony.com
Thu May 10 16:46:05 UTC 2018


> -----Original Message-----
> From: Daniel Sangorrin [mailto:daniel.sangorrin at toshiba.co.jp]
> Sent: Wednesday, May 09, 2018 4:47 PM
> To: Bird, Timothy <Tim.Bird at sony.com>; fuego at lists.linuxfoundation.org
> Subject: RE: [Fuego] [PATCH] ftc: add user_check for when ftc is executed as
> root
> 
> > -----Original Message-----
> > From: Tim.Bird at sony.com [mailto:Tim.Bird at sony.com]
> > Sent: Thursday, May 10, 2018 4:00 AM
> > To: daniel.sangorrin at toshiba.co.jp; fuego at lists.linuxfoundation.org
> > Subject: RE: [Fuego] [PATCH] ftc: add user_check for when ftc is executed
> as root
> >
> >
> >
> > > -----Original Message-----
> > > From: Daniel Sangorrin
> > >
> > > Signed-off-by: Daniel Sangorrin <daniel.sangorrin at toshiba.co.jp>
> > > ---
> > >  engine/scripts/ftc | 2 ++
> > >  1 file changed, 2 insertions(+)
> > >
> > > diff --git a/engine/scripts/ftc b/engine/scripts/ftc
> > > index 2029c55..123da65 100755
> > > --- a/engine/scripts/ftc
> > > +++ b/engine/scripts/ftc
> > > @@ -4297,9 +4297,11 @@ def main():
> > >
> > >      if command.startswith("build-job"):
> > >          # build jenkins jobs
> > > +        user_check()
> > >          do_build_jobs(conf, options)
> > >
> > >      if command == "add-view":
> > > +        user_check()
> > >          do_add_view(conf, options)
> > >
> > >      if command == "list-plans":
> > > --
> > > 2.7.4
> >
> > This looks OK.
> >
> > Can you remind me why it's good to switch user accounts here?
> > I know this switches from root to jenkins, but I can't remember why that's
> > good.
> 
> Ah sorry, I should have written something on the commit log. If you don't
> switch from root to jenkins, it is not possible to communicate with the server
> (an error appears saying something like couldn't connect to localhost/fuego).

OK - thanks.
 -- Tim


More information about the Fuego mailing list