saltstack / salt

Software to automate the management and configuration of any infrastructure or application at scale. Get access to the Salt software package repository here:
https://repo.saltproject.io/
Apache License 2.0
14.17k stars 5.48k forks source link

[DOCS] Documentation Inconsistency #66799

Open kevin-andrew-wipro opened 2 months ago

kevin-andrew-wipro commented 2 months ago

There appears to be some inconsistencies in the documentation and it is leading to some errors. On https://docs.saltproject.io/en/latest/topics/tutorials/master-cluster.html#tutorial-master-cluster it lists the following:

Master Config:

id: 10.27.12.13
cluster_id: master_cluster
cluster_peers:
  - 10.27.7.126
  - 10.27.3.73
cluster_pki_dir: /my/gluster/share/pki
cachedir: /my/gluster/share/cache
file_roots:
    - /my/gluster/share/srv/salt
pillar_roots:
    - /my/gluster/share/srv/pillar

In particular, note the file_roots and pillar_roots. If we run with this configuration, we end up with the following in the log file:

The file_roots parameter is not properly formatted, using defaults

image

The documentation on https://docs.saltproject.io/en/latest/ref/configuration/master.html#file-roots would seem to suggest that we need to use:

file_roots:
  base:
    - /my/gluster/share/srv/salt

Also, notice in the sample Master Config file, it uses cluster_pki_dir. Yet the documentation on https://docs.saltproject.io/en/latest/ref/configuration/master.html#cluster-pki-dir only shows cluster_pki. So which is it? image

welcome[bot] commented 2 months ago

Hi there! Welcome to the Salt Community! Thank you for making your first contribution. We have a lengthy process for issues and PRs. Someone from the Core Team will follow up as soon as possible. In the meantime, here’s some information that may help as you continue your Salt journey. Please be sure to review our Code of Conduct. Also, check out some of our community resources including:

There are lots of ways to get involved in our community. Every month, there are around a dozen opportunities to meet with other contributors and the Salt Core team and collaborate in real time. The best way to keep track is by subscribing to the Salt Community Events Calendar. If you have additional questions, email us at saltproject@vmware.com. We’re glad you’ve joined our community and look forward to doing awesome things with you!

clayoster commented 1 month ago

In particular, note the file_roots and pillar_roots. If we run with this configuration, we end up with the following in the log file:

The file_roots parameter is not properly formatted, using defaults

This would be the appropriate syntax for file_roots and pillar_roots assuming you are using the base environment.

file_roots:
  base:
    - /my/gluster/share/srv/salt
pillar_roots:
  base:
    - /my/gluster/share/srv/pillar

Also, notice in the sample Master Config file, it uses cluster_pki_dir. Yet the documentation on https://docs.saltproject.io/en/latest/ref/configuration/master.html#cluster-pki-dir only shows cluster_pki. So which is it? image

I believe cluster_pki_dir is the correct setting here. I have been using that in my deployment and it works as expected.