Skip to content

Commit

Permalink
fix(base): disable ntp installed on noble (#386)
Browse files Browse the repository at this point in the history
* fix(base): disable ntp installed on noble

* feat(base): add timesyncd state

* Update salt/base/sanity.sls

* chore: simplify code block

* feat: add new custom grain check for containers
  • Loading branch information
JacobCoffee authored Jul 17, 2024
1 parent 4df4a07 commit a01b900
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions salt/base/sanity.sls
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,19 @@ niceties:
- htop
- traceroute

time-sync:
{% if grains["oscodename"] in ["noble"] %}
systemd-timesyncd:
pkg:
- installed
service:
{% if grains["detect_virt"] in ["docker"] %}
- enabled
{% else %}
- running
- enable: True
{% endif %}
{% else %}
ntp-packages:
pkg.installed:
- pkgs:
- ntp
Expand All @@ -15,7 +27,7 @@ ntp:
service:
- running
- enable: True

{% endif %}

# Cron has a default $PATH of only /usr/bin:/bin, however the root user's
# default $PATH in the shell includes various sbin directories. This can cause
Expand Down

0 comments on commit a01b900

Please sign in to comment.