Require a relative sls file
See original GitHub issueRef. #5098
It looks like the require statement takes an absolute path to the required sls file. It would be cool if it could also support relative sls files, e.g.:
include:
- .local
somename:
- somemodule:somefunction
- require:
sls: .local
Today (0.17.5) the last require statement would have to read sls: path.to.here.local
Issue Analytics
- State:
- Created 10 years ago
- Reactions:6
- Comments:13 (10 by maintainers)
Top Results From Across the Web
Include and Exclude - Salt Project Documentation
Salt SLS files can include other SLS files and exclude SLS files that have been otherwise included. This allows for an SLS file...
Read more >Dealing with relative paths in saltstack for state files and for ...
I want to use relative paths when including sls files. This approach works when including state files but does not work when including...
Read more >Relative paths in SLS files (include and source) - Google Groups
Is there any way to specify relarive paths in these two cases ? I have searched the online documentation and found nothing about...
Read more >Include and Exclude - Read the Docs
Salt sls files can include other sls files and exclude sls files that have been otherwise included. This allows for an sls file...
Read more >SLS Structure - idem
Include# · Directories are dot delimited and relative to the directory of the current file. · The final entry in a dot delimited...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’ve recently run into this problem. Big +1 to supporting relative requires for sls files.
As a workaround one can use
slspath
variable: