[pmon]: Run ledd using python3 unless excluded (#6528)

**- Why I did it**

Ledd is the last daemon that is not enabled to run in python3.
Even though there is a plan to deprecate this daemon and to replace it by something else it's one simple step toward python2 deprecation.

**- How I did it**

Changed the `command=` line for `ledd` in the `supervisord` configuration of `pmon`.
Copied what was done for other daemons.

**- How to verify it**

Booting a product that has a `led_control.py` should now show the ledd running in python3.
I ran `python3 -m pylint` on all `led_control.py` plugin which means that most of them should be python3 compliant.
There is however still a risk that some might not work.
This commit is contained in:
Samuel Angebault 2021-01-22 07:12:01 -08:00 committed by GitHub
parent 8729fdc9ed
commit 0464d15b18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -68,7 +68,7 @@ dependent_startup_wait_for=rsyslogd:running
{% if not skip_ledd %}
[program:ledd]
command=/usr/local/bin/ledd
command={% if API_VERSION == 3 and 'ledd' not in python2_daemons %}python3 {% else %} python2 {% endif %}/usr/local/bin/ledd
priority=5
autostart=false
autorestart=false