2
0
Commit Graph

7 Commits

Author SHA1 Message Date
myii
91b666c75f Improve limitations related to git.latest in salt.formulas (#239)
* Ensure options for formulas `git.latest` are also based on defaults

* Prevent erroneous remote tracking branch modification by `salt.formulas` #238

* Allow multiple envs to use the same gitdir for `salt.formulas`

* Ensure `gitdir` original branch is checked out after formulas `git.latest`

* Fix erroneous comment re: merging in `salt` pillar
2018-06-10 11:18:20 +02:00
Matthew X. Economou
e8021220b8 Revert PR #200
This restores the original structure/behavior of the
`salt_formulas` Pillar key.
2016-02-16 10:20:42 -05:00
Thomas Larsen
d1cbec3fe2 Added support for downloading formulas from multiple baseurls into the same environment. 2016-02-08 13:45:09 +00:00
Matthew X. Economou
827ed47a25 Filter all calls to formulas_git_opt through load_yaml
Jinja macros are not actually functions.  The only thing they can return
is a string.  In order to return structured data, the callee must
serialize it, and the caller must deserialize it.  This state formula
uses YAML as the intermediary, hence the occurrence of both the
`|yaml` (callee) and `|load_yaml` (caller) filters in its code.

The post-render "mapping values are not allowed here" error in
*salt/formulas.sls* or the broken rendering of
*salt/files/master.d/f_defaults.conf* happens because invocations of the
`formulas_git_opt` macro in several Jinja `set` statements do not get
deserialized, resulting in the trailing newline followed by three dot
characters (`...`), which YAML uses to signal the end of a document.
Correcting these rendering errors requires adding the necessary
deserialization code at those locations (i.e., filtering the macro call
through `|load_yaml`).
2015-09-03 14:56:45 -04:00
Brian Jackson
9779609bc4 Remove mapping test
This test isn't available in certain popular versions of Jinja (namely the one
installed by default in CentOS 6).
2015-08-27 17:37:53 -05:00
Petr Demin
d4180295e3 formulas.jinja: python 2.6 support 2015-06-17 17:12:28 +03:00
Raphaël Hertzog
f46b4f29d8 Add new “salt.formulas” state to manage salt formulas
This state downloads formulas from git repositories and ensures
that they are recorded in the file_roots setting.
2014-12-23 17:24:19 +01:00