RicardoGustavo / neatx

Automatically exported from code.google.com/p/neatx
0 stars 0 forks source link

Fedora .spec needs to chown nx:nx /home/.nxhome #40

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The Fedora spec file leaves ownership of /home/.nxhome as root:root, meaning 
neatx can't create /home/.nxhome/.Xauthority , and you get a timeout error 
when the client is trying to connect.  The correct ownership should be nx:nx.  
This was also a problem in the Ubuntu build at one point (Issue 30).

Original issue reported on code.google.com by luke.hutch on 20 Jan 2010 at 7:04

GoogleCodeExporter commented 8 years ago
I'm not really familiar with fedora packaging, but i'm guessing this will fix 
the issue:

diff --git a/extras/rpm/neatx.spec b/extras/rpm/neatx.spec
index 987e0a4..285dc9e 100644
--- a/extras/rpm/neatx.spec
+++ b/extras/rpm/neatx.spec
@@ -64,6 +64,7 @@ getent group nx >/dev/null || groupadd -r nx
 getent passwd nx >/dev/null || \
        useradd -r -g nx -m -d %nx_homedir -s %_libdir/%{name}/nxserver-login-wrapper \
       -c "System account for the %{name} package" nx
+chown nx: %nx_homedir
 exit 0

 %post

Can you test it and let me know? Thanks,

Steve

Original comment by kormat on 24 Jan 2010 at 3:47

GoogleCodeExporter commented 8 years ago
Thanks Steve.  That fix looks like it's in the right place, although you should 
also 
add the -R switch to chown just in case (useradd can create some default home 
structure below the user home dir, I believe).

Original comment by luke.hutch on 24 Jan 2010 at 5:23

GoogleCodeExporter commented 8 years ago
I tested your patch and it works fine for me.  Yes, the -R switch is probably 
needed, useradd does indeed set up a default directory structure, and I guess 
it's 
possible for that to include the /home/.nxhome/.ssh directory.

Original comment by luke.hutch on 24 Jan 2010 at 5:46

GoogleCodeExporter commented 8 years ago
Alrighty, updated patch out for review. Cheers for testing this and providing 
feedback!

Steve

Original comment by kormat on 8 Feb 2010 at 5:22

GoogleCodeExporter commented 8 years ago
Thanks Steve!  Much appreciated.  What's the chance of getting this RPM 
submitted to 
the Fedora project?  After applying the patches to the three or so minor bugs I 
submitted here, the RPM works flawlessly.

Thanks,
Luke

Original comment by luke.hutch on 8 Feb 2010 at 5:39

GoogleCodeExporter commented 8 years ago
Patch committed. Re: submission to fedora, as i understand it, that would 
require a 
fedora package maintainer to adopt the package (see 
http://fedoraproject.org/wiki/PackageMaintainers/Join for example). 

Steve

Original comment by kormat on 8 Feb 2010 at 6:22