On 2015-11-18 00:01, l...@gnu.org wrote:
宋文武 <iyzs...@gmail.com> skribis:
* gnu/services/networking.scm (network-manager-service): New
procedure.
(network-manager-service-type, %network-manager-activation): New
variables.
(network-manager-dmd-service): New procedure.
[...]
+(define (network-manager-dmd-service network-manager)
+ "Return a dmd service for NETWORK-MANAGER."
+ (list (dmd-service
+ (documentation "Run the NetworkManager.")
+ (provision '(networking))
+ (requirement '(user-processes dbus-system loopback))
+ (start #~(make-forkexec-constructor
+ (list (string-append #$network-manager
+ "/sbin/NetworkManager")
+ "--no-daemon")))
+ (stop #~(make-kill-destructor)))))
I guess that even if NM can be activated by dbus-daemon, we prefer to
start it explicitly like this, right?
I suppose relying on dbus activation means that you could end up with
no
networking until you actually start network-manager-applet or one of
these clients.
I haven't test the dbus activatation, at lease nmcli won't do that.
Yes, and having a dmd service is convenient.
+ ;; Add network-manager to the system profile.
+ ;; XXX: Should we add network-manager-applet?
+ (service-extension profile-service-type
list)))))
I think network-manager-applet could be added to profile-service-type,
but only as part of %desktop-services. WDYT?
OK, that make sence.
Otherwise LGTM!
In a subsequent patch, you can add network-manager-service to
%desktop-services I guess. :-)
I only push this, because %desktop-services aleadly contains
wicd-service.
And more important, I haven't test wireless network (my card don't work
with linux-libre).
Thanks for the review!