Re: [systemd-devel] user instance of systemd while inside a container

2015-07-27 Thread Keller, Jacob E
On Mon, 2015-07-27 at 21:51 +0200, Lennart Poettering wrote:
> On Tue, 14.07.15 18:34, Keller, Jacob E (jacob.e.kel...@intel.com) 
> wrote:
> 
> > Hello,
> > 
> > I created an nspawn container which is also running systemd. I 
> > can't
> > figure out why the systemd --user instances aren't started.
> > 
> > I'd like to manage some processes run as a specific user inside the
> > container. Previously I was using a VM to do it this way, and I 
> > would
> > like to be able to port the same code over to the container image.
> > 
> > Is there some setup I need to do to get the instance started? I 
> > tried
> > searching on the web, but came up with very little documentation. 
> > user
> > instances appear to be started by pam.. Maybe pam is not being used 
> > as
> > the login for the container?
> 
> This should just work, and it works for me too, with a Fedora 22 host
> and guest (with current systemd added on top).
> 
> Anything interesting in the logs?
> 
> What does "systemctl status user@$UID.service" say for you after you
> logged in?
> 
> Lennart
> 

Hi, thanks. I found out it was because I am using Centos, which
disables this feature by default. I had to copy a user@.service into
the container, and then things worked fine. Wish downstream projects
wouldn't disable random features like this 

Regards,
Jake
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] user instance of systemd while inside a container

2015-07-27 Thread Lennart Poettering
On Tue, 14.07.15 18:34, Keller, Jacob E (jacob.e.kel...@intel.com) wrote:

> Hello,
> 
> I created an nspawn container which is also running systemd. I can't
> figure out why the systemd --user instances aren't started.
> 
> I'd like to manage some processes run as a specific user inside the
> container. Previously I was using a VM to do it this way, and I would
> like to be able to port the same code over to the container image.
> 
> Is there some setup I need to do to get the instance started? I tried
> searching on the web, but came up with very little documentation. user
> instances appear to be started by pam.. Maybe pam is not being used as
> the login for the container?

This should just work, and it works for me too, with a Fedora 22 host
and guest (with current systemd added on top).

Anything interesting in the logs?

What does "systemctl status user@$UID.service" say for you after you
logged in?

Lennart

-- 
Lennart Poettering, Red Hat
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


[systemd-devel] user instance of systemd while inside a container

2015-07-14 Thread Keller, Jacob E
Hello,

I created an nspawn container which is also running systemd. I can't
figure out why the systemd --user instances aren't started.

I'd like to manage some processes run as a specific user inside the
container. Previously I was using a VM to do it this way, and I would
like to be able to port the same code over to the container image.

Is there some setup I need to do to get the instance started? I tried
searching on the web, but came up with very little documentation. user
instances appear to be started by pam.. Maybe pam is not being used as
the login for the container?

Is the only alternative to put a bunch of system level services and
label them as User=specificuser

Thanks for your help.

Regards,
Jake
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel