saltstack内置state模块file之append

添加文件文本在文件尾部

salt.states.file.append(name, text=None, makedirs=False, source=None, source_hash=None, template='jinja', sources=None, source_hashes=None, defaults=None, context=None)

name

被附加文件的路径

text

被添加字符串,一行或一列

makedirs

默认为False,如需要添加的文件父目录不存在则文件添加失败,设置为True,则会创建父目录。

template

默认为jinja,添加到文件的模块引擎

原文地址:https://www.cnblogs.com/jim-hwg/p/4613691.html