Disclaimer: It's a prototype full of unexpected behavior like throwing nondescript errors when using single quotes when it expects double quotes. I fully intend to rip out the prototype code and replace it with proper salt template rendering code. Just have to find the time to dig into it.
Jinjabread is a very simple jinja syntax checking tool for creating SaltStack states.
It's divided into 4 windows, Grains, Pillar, State and Output, assuming you're familiar with SaltStack this does not require much explanation. If none of that makes sense, SaltStack is a Remote Execution Framework with Configuration Management capabilities. If you're a sysadmin/devops/ITguy supporting IT infrastructure of any size, SaltStack is great and you should check it out.
Essentially, you type in the grains and pillar data you want, write your state template with your jinja2, press ctrl+b
or click the render button.
If things go well, it produces the state in the output to make sure it rendered correctly. If an error has occured it should tell you with relative accuracy where it went wrong.
But, why?
Figuring out where and why your state broke can be an arduous task, especially if you are just starting out with SaltStack for the first time. This tool aims to help either getting started writing states, or just debugging that one state you just can't seem to fix.
I hope you enjoy it
Try a demo at jinjabread.christopherbaklid.com
- Renders Jinja2 and YAML
- Shareable links to share with others for help
- Proper salt integration, to use salt modules
- Support for multiline comments
{# multiline comment #}
throws some confusingyaml
syntax errors
- Does not work in Internet Explorer
python 3.5+ pipenv 2018+
git clone https://github.com/Inveracity/jinjabread.git
cd jinjabread
pip install pipenv
pipenv sync
pipenv run start
Browse to localhost:5000
pipenv run build
docker run -d -p 80:80 --name jinjabread jinjabread:latest
Browse to localhost/
SaltStack - Extensive use of their code from github
Codemirror - Code highlighting in textarea
Bootstrap3 - general styling
jqueryUI - Resizable divs
PersistState - persist jqueryUI through refresh