services: network-manager: Create '/var/lib/misc' directory for dnsmasq.
* gnu/services/networking.scm (%network-manager-activation): Rename to... (network-manager-activation): ... this and make it a procedure. Make it create '/var/lib/misc' when using dnsmasq. (network-manager-service-type): Use it. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
parent
0207ebf0e9
commit
57c16c97cb
|
@ -895,11 +895,17 @@ and @command{wicd-curses} user interfaces."
|
||||||
(vpn-plugins network-manager-vpn-plugins ;list of <package>
|
(vpn-plugins network-manager-vpn-plugins ;list of <package>
|
||||||
(default '())))
|
(default '())))
|
||||||
|
|
||||||
(define %network-manager-activation
|
(define network-manager-activation
|
||||||
;; Activation gexp for NetworkManager.
|
;; Activation gexp for NetworkManager
|
||||||
|
(match-lambda
|
||||||
|
(($ <network-manager-configuration> network-manager dns vpn-plugins)
|
||||||
#~(begin
|
#~(begin
|
||||||
(use-modules (guix build utils))
|
(use-modules (guix build utils))
|
||||||
(mkdir-p "/etc/NetworkManager/system-connections")))
|
(mkdir-p "/etc/NetworkManager/system-connections")
|
||||||
|
#$@(if (equal? dns "dnsmasq")
|
||||||
|
;; create directory to store dnsmasq lease file
|
||||||
|
'((mkdir-p "/var/lib/misc"))
|
||||||
|
'())))))
|
||||||
|
|
||||||
(define (vpn-plugin-directory plugins)
|
(define (vpn-plugin-directory plugins)
|
||||||
"Return a directory containing PLUGINS, the NM VPN plugins."
|
"Return a directory containing PLUGINS, the NM VPN plugins."
|
||||||
|
@ -949,7 +955,7 @@ and @command{wicd-curses} user interfaces."
|
||||||
(service-extension dbus-root-service-type config->package)
|
(service-extension dbus-root-service-type config->package)
|
||||||
(service-extension polkit-service-type config->package)
|
(service-extension polkit-service-type config->package)
|
||||||
(service-extension activation-service-type
|
(service-extension activation-service-type
|
||||||
(const %network-manager-activation))
|
network-manager-activation)
|
||||||
(service-extension session-environment-service-type
|
(service-extension session-environment-service-type
|
||||||
network-manager-environment)
|
network-manager-environment)
|
||||||
;; Add network-manager to the system profile.
|
;; Add network-manager to the system profile.
|
||||||
|
|
Loading…
Reference in New Issue