All of lore.kernel.org
 help / color / mirror / Atom feed
* [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root
@ 2018-05-09  8:05 Daniel Sangorrin
  2018-05-09 18:59 ` Tim.Bird
  0 siblings, 1 reply; 4+ messages in thread
From: Daniel Sangorrin @ 2018-05-09  8:05 UTC (permalink / raw)
  To: fuego

Signed-off-by: Daniel Sangorrin <daniel.sangorrin@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



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root
  2018-05-09  8:05 [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root Daniel Sangorrin
@ 2018-05-09 18:59 ` Tim.Bird
  2018-05-09 23:47   ` Daniel Sangorrin
  0 siblings, 1 reply; 4+ messages in thread
From: Tim.Bird @ 2018-05-09 18:59 UTC (permalink / raw)
  To: daniel.sangorrin, fuego



> -----Original Message-----
> From: Daniel Sangorrin
> 
> Signed-off-by: Daniel Sangorrin <daniel.sangorrin@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.

Thanks for the patch. Applied and pushed.
 -- Tim


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root
  2018-05-09 18:59 ` Tim.Bird
@ 2018-05-09 23:47   ` Daniel Sangorrin
  2018-05-10 16:46     ` Tim.Bird
  0 siblings, 1 reply; 4+ messages in thread
From: Daniel Sangorrin @ 2018-05-09 23:47 UTC (permalink / raw)
  To: Tim.Bird, fuego

> -----Original Message-----
> From: Tim.Bird@sony.com [mailto:Tim.Bird@sony.com]
> Sent: Thursday, May 10, 2018 4:00 AM
> To: daniel.sangorrin@toshiba.co.jp; fuego@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@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).

Thanks,
Daniel



> 
> Thanks for the patch. Applied and pushed.
>  -- Tim
> 




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root
  2018-05-09 23:47   ` Daniel Sangorrin
@ 2018-05-10 16:46     ` Tim.Bird
  0 siblings, 0 replies; 4+ messages in thread
From: Tim.Bird @ 2018-05-10 16:46 UTC (permalink / raw)
  To: daniel.sangorrin, fuego

> -----Original Message-----
> From: Daniel Sangorrin [mailto:daniel.sangorrin@toshiba.co.jp]
> Sent: Wednesday, May 09, 2018 4:47 PM
> To: Bird, Timothy <Tim.Bird@sony.com>; fuego@lists.linuxfoundation.org
> Subject: RE: [Fuego] [PATCH] ftc: add user_check for when ftc is executed as
> root
> 
> > -----Original Message-----
> > From: Tim.Bird@sony.com [mailto:Tim.Bird@sony.com]
> > Sent: Thursday, May 10, 2018 4:00 AM
> > To: daniel.sangorrin@toshiba.co.jp; fuego@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@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

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-05-10 16:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-09  8:05 [Fuego] [PATCH] ftc: add user_check for when ftc is executed as root Daniel Sangorrin
2018-05-09 18:59 ` Tim.Bird
2018-05-09 23:47   ` Daniel Sangorrin
2018-05-10 16:46     ` Tim.Bird

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.