1DBUS-UPDATE-ACTIVA(1)            User Commands           DBUS-UPDATE-ACTIVA(1)
2
3
4

NAME

6       dbus-update-activation-environment - update environment used for D-Bus
7       session services
8

SYNOPSIS

10       dbus-update-activation-environment [--systemd] [--verbose] --all |
11                                          VAR... | VAR=VAL...
12

DESCRIPTION

14       dbus-update-activation-environment updates the list of environment
15       variables used by dbus-daemon --session when it activates session
16       services without using systemd.
17
18       With the --systemd option, if an instance of systemd --user is
19       available on D-Bus, it also updates the list of environment variables
20       used by systemd --user when it activates user services, including D-Bus
21       session services for which dbus-daemon has been configured to delegate
22       activation to systemd. This is very similar to the import-environment
23       command provided by systemctl(1)).
24
25       Variables that are special to dbus-daemon or systemd may be set, but
26       their values will be overridden when a service is started. For
27       instance, it is not useful to add DBUS_SESSION_BUS_ADDRESS to
28       dbus-daemon's activation environment, although it might still be useful
29       to add it to systemd's activation environment.
30

OPTIONS

32       --all
33           Set all environment variables present in the environment used by
34           dbus-update-activation-environment.
35
36       --systemd
37           Set environment variables for systemd user services as well as for
38           traditional D-Bus session services.
39
40       --verbose
41           Output messages to standard error explaining what
42           dbus-update-activation-environment is doing.
43
44       VAR
45           If VAR is present in the environment of
46           dbus-update-activation-environment, set it to the same value for
47           D-Bus services. Its value must be UTF-8 (if not, it is skipped with
48           a warning). If VAR is not present in the environment, this argument
49           is silently ignored.
50
51       VAR=VAL
52           Set VAR to VAL, which must be UTF-8.
53

EXAMPLES

55       dbus-update-activation-environment is primarily designed to be used in
56       Linux distributions' X11 session startup scripts, in conjunction with
57       the "user bus" design.
58
59       To propagate DISPLAY and XAUTHORITY to dbus-daemon and, if present,
60       systemd, and propagate DBUS_SESSION_BUS_ADDRESS to systemd:
61
62                   dbus-update-activation-environment --systemd \
63                       DBUS_SESSION_BUS_ADDRESS DISPLAY XAUTHORITY
64
65
66       To propagate all environment variables except XDG_SEAT, XDG_SESSION_ID
67       and XDG_VTNR to dbus-daemon (and, if present, systemd) for
68       compatibility with legacy X11 session startup scripts:
69
70                   # in a subshell so the variables remain set in the
71                   # parent script
72                   (
73                     unset XDG_SEAT
74                     unset XDG_SESSION_ID
75                     unset XDG_VTNR
76
77                     dbus-update-activation-environment --systemd --all
78                   )
79
80
81

EXIT STATUS

83       dbus-update-activation-environment exits with status 0 on success,
84       EX_USAGE (64) on invalid command-line options, EX_OSERR (71) if unable
85       to connect to the session bus, or EX_UNAVAILABLE (69) if unable to set
86       the environment variables. Other nonzero exit codes might be added in
87       future versions.
88

ENVIRONMENT

90       DBUS_SESSION_BUS_ADDRESS, XDG_RUNTIME_DIR and/or DISPLAY are used to
91       find the address of the session bus.
92

LIMITATIONS

94       dbus-daemon does not provide a way to unset environment variables after
95       they have been set (although systemd does), so
96       dbus-update-activation-environment does not offer this functionality
97       either.
98
99       POSIX does not specify the encoding of non-ASCII environment variable
100       names or values and allows them to contain any non-zero byte, but
101       neither dbus-daemon nor systemd supports environment variables with
102       non-UTF-8 names or values. Accordingly,
103       dbus-update-activation-environment assumes that any name or value that
104       appears to be valid UTF-8 is intended to be UTF-8, and ignores other
105       names or values with a warning.
106

BUGS

108       Please send bug reports to the D-Bus bug tracker or mailing list. See
109       http://www.freedesktop.org/software/dbus/.
110

SEE ALSO

112       dbus-daemon(1), systemd(1), the import-environment command of
113       systemctl(1)
114
116       Copyright © 2015 Collabora Ltd.
117
118       This man page is distributed under the same terms as
119       dbus-update-activation-environment (MIT/X11). There is NO WARRANTY, to
120       the extent permitted by law.
121
122
123
124
125D-Bus 1.12.20                     01/26/2021             DBUS-UPDATE-ACTIVA(1)
Impressum