Line 0
Link Here
|
|
|
1 |
--- cloudinit/config/cc_salt_minion.py.orig 2021-01-15 17:33:05 UTC |
2 |
+++ cloudinit/config/cc_salt_minion.py |
3 |
@@ -46,7 +46,7 @@ specify them with ``pkg_name``, ``service_name`` and ` |
4 |
import os |
5 |
|
6 |
from cloudinit import safeyaml, subp, util |
7 |
-from cloudinit.distros import rhel_util |
8 |
+from cloudinit.distros import bsd_utils |
9 |
|
10 |
|
11 |
# Note: see https://docs.saltstack.com/en/latest/topics/installation/ |
12 |
@@ -125,8 +141,7 @@ def handle(name, cfg, cloud, log, _args): |
13 |
# we need to have the salt minion service enabled in rc in order to be |
14 |
# able to start the service. this does only apply on FreeBSD servers. |
15 |
if cloud.distro.osfamily == 'freebsd': |
16 |
- rhel_util.update_sysconfig_file( |
17 |
- '/etc/rc.conf', {'salt_minion_enable': 'YES'}) |
18 |
+ bsd_utils.set_rc_config_value('salt_minion_enable', 'YES') |
19 |
|
20 |
# restart salt-minion. 'service' will start even if not started. if it |
21 |
# was started, it needs to be restarted for config change. |