Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,29 @@ dependent_startup_wait_for=rsyslogd:running {% if delay_non_critical_daemon %}de

{% if not skip_thermalctld %}
[program:thermalctld]
command={% if API_VERSION == 3 and 'thermalctld' not in python2_daemons %}python3 {% else %} python2 {% endif %}/usr/local/bin/thermalctld
{% set base_command = (
"python3 /usr/local/bin/thermalctld"
if API_VERSION == 3 and 'thermalctld' not in python2_daemons
else "python2 /usr/local/bin/thermalctld"
) %}
{% set options = "" -%}

{% if thermalctld is defined %}
{% if thermalctld.thermal_monitor_initial_interval is defined and thermalctld.thermal_monitor_initial_interval is not none %}
{%- set options = options + " --thermal-monitor-initial-interval " + thermalctld.thermal_monitor_initial_interval|string %}
{% endif -%}

{% if thermalctld.thermal_monitor_update_interval is defined and thermalctld.thermal_monitor_update_interval is not none %}
{%- set options = options + " --thermal-monitor-update-interval " + thermalctld.thermal_monitor_update_interval|string %}
{% endif -%}

{% if thermalctld.thermal_monitor_update_elapsed_threshold is defined and thermalctld.thermal_monitor_update_elapsed_threshold is not none %}
{%- set options = options + " --thermal-monitor-update-elapsed-threshold " + thermalctld.thermal_monitor_update_elapsed_threshold|string %}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but please add details in PR description on the new intervals and which daemon/thread in thermalctld it will affect

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @judyjoseph , I have updated the PR description to document this, please take a look.

{% endif -%}
{% endif -%}

{%- set command = base_command ~ options %}
command={{ command }}
priority=10
autostart=false
autorestart=unexpected
Expand Down
Loading