Bug 244756

Summary: x11/sddm: /etc/ isn't a place for home directories
Product: Ports & Packages Reporter: Colin Percival <cperciva>
Component: Individual Port(s)Assignee: Gleb Popov <arrowd>
Status: Closed FIXED    
Severity: Affects Only Me CC: adridg, arrowd, jonc, kde, sv, tcberner
Priority: --- Flags: tcberner: maintainer-feedback+
Version: Latest   
Hardware: Any   
OS: Any   
Description Flags
Proposed patch arrowd: maintainer-approval? (kde)

Description Colin Percival freebsd_committer 2020-03-12 14:41:16 UTC
The UIDs entry for sddm places its home directory in /usr/local/etc/sddm/home:

sddm:*:219:219::0:0:SDDM Display Manager user:/usr/local/etc/sddm/home:/usr/sbin/nologin

This seems like a bad idea, since /usr/local/etc/ normally holds configuration files, and is often managed via systems designed for that purpose; having it contain a home directory is liable to cause unintended results.

It seems to me that the home directory should probably be somewhere under /var/
Comment 1 Tobias C. Berner freebsd_committer 2020-03-12 19:19:37 UTC
Moin moin 

Sure, I see no problem with moving it in principal.
It may have been that we took gdm, which  does the same as a template... too long ago to remember :)

mfg Tobias
Comment 2 Tobias C. Berner freebsd_committer 2020-03-28 07:59:30 UTC
*** Bug 245117 has been marked as a duplicate of this bug. ***
Comment 3 Gleb Popov freebsd_committer 2020-05-16 18:27:18 UTC
Created attachment 214561 [details]
Proposed patch
Comment 4 Tobias C. Berner freebsd_committer 2020-05-16 18:37:57 UTC
It would probably not hurt to also add an UPDATING entry with the command to run when updating.
Comment 5 Adriaan de Groot freebsd_committer 2020-05-16 20:42:36 UTC
The UPDATING entry can be the same at the upgrade message, **but** ..

Note that /usr/local/etc/sddm/home may contain some files already (in particular, `state.conf`) that have a real effect. The message should either explicitly mention moving the `state.conf` file, or mention that you'll need to select a user and session anew.
Comment 6 commit-hook freebsd_committer 2020-05-17 08:21:48 UTC
A commit references this bug:

Author: arrowd
Date: Sun May 17 08:21:06 UTC 2020
New revision: 535524
URL: https://svnweb.freebsd.org/changeset/ports/535524

  x11/sddm: Switch SDDM user's HOME directory from /usr/local/etc/sddm/home to
  /var/lib/sddm, as sddm(5) man page requests.

  PR:		244756
  Reviewed by:	tcberner, adridg

Comment 7 commit-hook freebsd_committer 2020-05-17 08:44:55 UTC
A commit references this bug:

Author: arrowd
Date: Sun May 17 08:44:12 UTC 2020
New revision: 535529
URL: https://svnweb.freebsd.org/changeset/ports/535529

  x11/sddm: Constrain upgrade pkg-message to pre 0.18.1_4 version.

  PR:		244756