VMware Aria

 View Only
  • 1.  SaltStack - state file

    Posted Dec 12, 2023 03:35 PM

    Hi - apologies if this is not the right place for SaltStack questions but I'm struggling for support. This (hopefully) is a simple question. The File.managed command is available to use in a salt state file to move individual files from the Salt Master to a Minion. However, File.Recurse looks to be the method to move all files from a folder on the master to a Minion according to online Salt documentation but does not seem to be available for use in VMWare SaltStack. Is there an alternative or am I missing something obvious ? Any help or useful advice would be much appreciated. Thanks



  • 2.  RE: SaltStack - state file

    Posted Dec 20, 2023 08:02 PM

    Something like this should work:

     

    copy_file_module:
      file.recurse:
        - name: /foo/bar
        - source: salt://qux/foo/bar
        - include_empty: True
        - makedirs: True

     

     

    But maybe a better approach would be to compress these files and have the minion download and extract the files.