sysuser: generate default snippet incorporating TTY_GID properly
When the user specifies --with-tty-gid= then we should honour that and write it to the snippet, too.
This commit is contained in:
parent
7ec9fb4be9
commit
f8b5d99408
|
@ -1772,9 +1772,12 @@ systemd_sysusers_LDADD = \
|
||||||
rootbin_PROGRAMS += \
|
rootbin_PROGRAMS += \
|
||||||
systemd-sysusers
|
systemd-sysusers
|
||||||
|
|
||||||
dist_sysusers_DATA = \
|
nodist_sysusers_DATA = \
|
||||||
sysusers.d/systemd.conf
|
sysusers.d/systemd.conf
|
||||||
|
|
||||||
|
EXTRA_DIST += \
|
||||||
|
sysusers.d/systemd.conf.in
|
||||||
|
|
||||||
INSTALL_DIRS += \
|
INSTALL_DIRS += \
|
||||||
$(sysusersdir)
|
$(sysusersdir)
|
||||||
endif
|
endif
|
||||||
|
@ -4934,7 +4937,8 @@ substitutions = \
|
||||||
'|NTP_SERVERS=$(NTP_SERVERS)|' \
|
'|NTP_SERVERS=$(NTP_SERVERS)|' \
|
||||||
'|DNS_SERVERS=$(DNS_SERVERS)|' \
|
'|DNS_SERVERS=$(DNS_SERVERS)|' \
|
||||||
'|systemuidmax=$(SYSTEM_UID_MAX)|' \
|
'|systemuidmax=$(SYSTEM_UID_MAX)|' \
|
||||||
'|systemgidmax=$(SYSTEM_GID_MAX)|'
|
'|systemgidmax=$(SYSTEM_GID_MAX)|' \
|
||||||
|
'|TTY_GID=$(TTY_GID)|'
|
||||||
|
|
||||||
SED_PROCESS = \
|
SED_PROCESS = \
|
||||||
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
|
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
|
||||||
|
|
|
@ -1050,8 +1050,11 @@ AM_CONDITIONAL(HAVE_SYSV_COMPAT, test "$SYSTEM_SYSV_COMPAT" = "yes")
|
||||||
AC_ARG_WITH([tty-gid],
|
AC_ARG_WITH([tty-gid],
|
||||||
[AS_HELP_STRING([--with-tty-gid=GID],
|
[AS_HELP_STRING([--with-tty-gid=GID],
|
||||||
[Specify the numeric GID of the 'tty' group])],
|
[Specify the numeric GID of the 'tty' group])],
|
||||||
[AC_DEFINE_UNQUOTED(TTY_GID, [$withval], [GID of the 'tty' group])],
|
[TTY_GID="$withval"],
|
||||||
[])
|
[TTY_GID="5"])
|
||||||
|
|
||||||
|
AC_DEFINE_UNQUOTED(TTY_GID, [$TTY_GID], [GID of the 'tty' group])
|
||||||
|
AC_SUBST(TTY_GID)
|
||||||
|
|
||||||
AC_ARG_WITH([dbuspolicydir],
|
AC_ARG_WITH([dbuspolicydir],
|
||||||
AS_HELP_STRING([--with-dbuspolicydir=DIR], [D-Bus policy directory]),
|
AS_HELP_STRING([--with-dbuspolicydir=DIR], [D-Bus policy directory]),
|
||||||
|
@ -1234,6 +1237,7 @@ AC_MSG_RESULT([
|
||||||
Extra start script: ${RC_LOCAL_SCRIPT_PATH_START}
|
Extra start script: ${RC_LOCAL_SCRIPT_PATH_START}
|
||||||
Extra stop script: ${RC_LOCAL_SCRIPT_PATH_STOP}
|
Extra stop script: ${RC_LOCAL_SCRIPT_PATH_STOP}
|
||||||
Debug shell: ${SUSHELL} @ ${DEBUGTTY}
|
Debug shell: ${SUSHELL} @ ${DEBUGTTY}
|
||||||
|
TTY GID: ${TTY_GID}
|
||||||
Maximum System UID: ${SYSTEM_UID_MAX}
|
Maximum System UID: ${SYSTEM_UID_MAX}
|
||||||
Maximum System GID: ${SYSTEM_GID_MAX}
|
Maximum System GID: ${SYSTEM_GID_MAX}
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@ g wheel - -
|
||||||
# Access to certain kernel and userspace facilities
|
# Access to certain kernel and userspace facilities
|
||||||
g kmem - -
|
g kmem - -
|
||||||
g lock - -
|
g lock - -
|
||||||
g tty 5 -
|
g tty @TTY_GID@ -
|
||||||
g utmp - -
|
g utmp - -
|
||||||
|
|
||||||
# Hardware access groups
|
# Hardware access groups
|
Loading…
Reference in New Issue