diff --git a/Makefile b/Makefile index 3ccfaf7..133d4c1 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,7 @@ install: uninstall: $(PIP) uninstall -y naxalnet - rm -rf /usr/share/naxalnet /usr/lib/systemd/system/naxalnet.service + rm -rf /usr/share/naxalnet /usr/lib/systemd/system/naxalnet.service /usr/lib/systemd/system/iwd.service.d/naxalnet.conf @echo "make uninstall will not remove anything in /etc/naxalnet" && \ echo "Do 'sudo make purge' to remove it." diff --git a/naxalnet/__init__.py b/naxalnet/__init__.py index a91face..0af1e6f 100644 --- a/naxalnet/__init__.py +++ b/naxalnet/__init__.py @@ -42,4 +42,4 @@ given below. # # In case you forgot to change the version, skip the number # and put the next number in the next commit. -__version__ = "0.5.0a1.dev1" +__version__ = "0.5.0a1.dev2" diff --git a/service/iwd.service.d/naxalnet.conf b/service/iwd.service.d/naxalnet.conf new file mode 100644 index 0000000..bc72d66 --- /dev/null +++ b/service/iwd.service.d/naxalnet.conf @@ -0,0 +1,4 @@ +[Unit] +# Fix for issue #21 +Conflicts=wpa_supplicant.service +After=wpa_supplicant.service diff --git a/service/naxalnet.service b/service/naxalnet.service index 2760618..1e04540 100644 --- a/service/naxalnet.service +++ b/service/naxalnet.service @@ -4,17 +4,19 @@ [Unit] Description=Setup mesh networks Requires=systemd-networkd.service -Requires=iwd.service +# See issue #21 to find out why we do not use Required for iwd +Wants=iwd.service Wants=systemd-resolved.service After=iwd.service After=systemd-networkd.service After=systemd-resolved.service # Stops NetworkManager and wpa_supplicant if already running Conflicts=NetworkManager.service -Conflicts=wpa_supplicant.service +# Commented out for testing +#Conflicts=wpa_supplicant.service # This stops networkmanager and wpa_supplicant when naxalnet is enabled After=NetworkManager.service -After=wpa_supplicant.service +#After=wpa_supplicant.service [Service] Type=notify diff --git a/setup.cfg b/setup.cfg index 67829aa..66b9760 100644 --- a/setup.cfg +++ b/setup.cfg @@ -34,6 +34,8 @@ console_scripts = [options.data_files] lib/systemd/system = service/naxalnet.service +lib/systemd/system/iwd.service.d = + service/iwd.service.d/naxalnet.conf # If installing with pip, this file will be copied to some other place. # This is the reason we use setup.py instead of pip in the Makefile. /etc/naxalnet =