Re: DisplayManagerRework: how to handle upgrades?

2012-08-11 Thread Rex Dieter
Rex Dieter wrote:

 Rex Dieter wrote:
 
 OK,  so we have
 https://fedoraproject.org/wiki/Features/DisplayManagerRework#How_To_Test
 
 that tells one how to enable the display manager of your choice, via
 systemctl enable --force xyzdm.service
 
 But, how to handle upgrades? (or is this case already handled somehow?)
 
 Off the top of my head, perhaps create some sort of scriptlet (probably
 to live in initscripts, since that's what owned prefdm) to parse
 /etc/sysconfig/desktop to make some educated guess about which dm service
 to enable.
 
 nucleo mentioned to me on irc the case also of the simple case of a
 machine
 with no DM.  If the expactation that
 yum install gdm
 (or any DM, with no DM currently enabled) should 'just work', then perhaps
 also consider doing something like this in gdm's %post scriptlet:
 systemctl is-enabled display-manager.service || \
   systemctl enable gdm.service

ok, ignore this, looks like presets are the way to go here.

-- rex


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: DisplayManagerRework: how to handle upgrades?

2012-08-11 Thread Lennart Poettering
On Sat, 11.08.12 11:23, Rex Dieter (rdie...@math.unl.edu) wrote:

 OK,  so we have  
 https://fedoraproject.org/wiki/Features/DisplayManagerRework#How_To_Test
 
 that tells one how to enable the display manager of your choice, via
 systemctl enable --force xyzdm.service
 
 But, how to handle upgrades? (or is this case already handled
 somehow?)

This should be handled already bei the postinst scriptlet in the systemd
RPM. I must admit though that I gave that bit only minimal testing. But
it should work, and the core of it is just copied out of the old prefdm
script, so that we closely convert the old settings into new settings.

 Off the top of my head, perhaps create some sort of scriptlet (probably to  
 live in initscripts, since that's what owned prefdm) to parse 
 /etc/sysconfig/desktop to make some educated guess about which dm service to 
 enable.

That's pretty much exactly what we have, except that this actually
resides in systemd.rpm.

Lennart

-- 
Lennart Poettering - Red Hat, Inc.
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: DisplayManagerRework: how to handle upgrades?

2012-08-11 Thread Lennart Poettering
On Sat, 11.08.12 21:54, alekc...@googlemail.com (alekc...@googlemail.com) wrote:

 Rex Dieter wrote:
 
  OK,  so we have
  https://fedoraproject.org/wiki/Features/DisplayManagerRework#How_To_Test
  
  that tells one how to enable the display manager of your choice, via
  systemctl enable --force xyzdm.service
  
  But, how to handle upgrades? (or is this case already handled somehow?)
  
  Off the top of my head, perhaps create some sort of scriptlet (probably to
  live in initscripts, since that's what owned prefdm) to parse
  /etc/sysconfig/desktop to make some educated guess about which dm service to
  enable.
  
  thoughts?
  
  -- rex
  
 
 This is marked as DONE:
 
 8. (Optionally) Patch systemd to parse /etc/sysconfig/desktop at upgrade time 
 and generate a symlink from it that is stored in 
 /etc/systemd/system/display-manager.service 
 and ensures that the original display manager choice is kept.
 
 I have DISPLAYMANAGER=KDE in /etc/sysconfig/desktop 
 but symlink was not generated after Rawhide update.

Hmm, that would suggest that this bit is borked:

http://pkgs.fedoraproject.org/cgit/systemd.git/tree/systemd.spec#n300

If you execute that by hand in a shell, does it work for you then?

Lennart

-- 
Lennart Poettering - Red Hat, Inc.
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: DisplayManagerRework: how to handle upgrades?

2012-08-11 Thread alekcejk
Lennart Poettering wrote:

 On Sat, 11.08.12 21:54, alekc...@googlemail.com (alekc...@googlemail.com) 
 wrote:
 
 Rex Dieter wrote:
 
  OK,  so we have
  https://fedoraproject.org/wiki/Features/DisplayManagerRework#How_To_Test
  
  that tells one how to enable the display manager of your choice, via
  systemctl enable --force xyzdm.service
  
  But, how to handle upgrades? (or is this case already handled somehow?)
  
  Off the top of my head, perhaps create some sort of scriptlet (probably to
  live in initscripts, since that's what owned prefdm) to parse
  /etc/sysconfig/desktop to make some educated guess about which dm service 
  to
  enable.
  
  thoughts?
  
  -- rex
  
 
 This is marked as DONE:
 
 8. (Optionally) Patch systemd to parse /etc/sysconfig/desktop at upgrade time
 and generate a symlink from it that is stored in
 /etc/systemd/system/display-manager.service
 and ensures that the original display manager choice is kept.
 
 I have DISPLAYMANAGER=KDE in /etc/sysconfig/desktop
 but symlink was not generated after Rawhide update.
 
 Hmm, that would suggest that this bit is borked:
 
 http://pkgs.fedoraproject.org/cgit/systemd.git/tree/systemd.spec#n300
 
 If you execute that by hand in a shell, does it work for you then?
 
 Lennart
 

This part of code creates symlink (after installing all
updates including systemd and kde-settings-kdm).

But as I commented in bug 847472, symlink also created
after updating systemd if kde-settings-kdm was previously
updated to version which adds kdm.servise.
If systemd and kde-settings both updated at once then
symlink not created.

https://bugzilla.redhat.com/show_bug.cgi?id=847472#c5

-- 
Alexey Kurov nuc...@fedoraproject.org

-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel