unable to load external pillar

111 views
Skip to first unread message

Akilesh K

unread,
Aug 8, 2014, 5:51:07 AM8/8/14
to salt-...@googlegroups.com
Hi,
I need help working with external pillar. I have this in my master config file

ext_pillar:
  - cloud_pillar: pillar_definitions
extension_modules:  /csrv/salt/ext_modules

On my master
root@akilesh-lenovo:/csrv/salt/ext_modules/pillar# ls
cloud_pillar.py


And this is what salt documentation says about external pillars loading.

And yet my external module is not loaded. Can someone please tell me what I am doing wrong/ What else has to be done?

Wolodja Wentland

unread,
Aug 9, 2014, 2:50:42 AM8/9/14
to salt-...@googlegroups.com
On Fri, Aug 08, 2014 at 15:21 +0530, Akilesh K wrote:
> I need help working with external pillar. I have this in my master config file
>
> ext_pillar:
>   - cloud_pillar: pillar_definitions
> extension_modules:  /csrv/salt/ext_modules

This is not correct (even if you ignore the "csrv" vs. "srv" typo). You want to
set "extension_modules" to the name of a subdirectory under root_dir as "This
path is appended to root_dir." [0]

I typically just put external modules in _modules (just like _grains, ...)
in file_roots though

[0]
http://docs.saltstack.com/en/latest/ref/configuration/master.html#extension-modules
--
Wolodja <bab...@gmail.com>

4096R/CAF14EFC
081C B7CD FF04 2BA9 94EA 36B2 8B7F 7D30 CAF1 4EFC
signature.asc

Akilesh K

unread,
Aug 11, 2014, 6:15:04 AM8/11/14
to salt-...@googlegroups.com
Hi,
As you said placing the file in _modules was sufficient. If I run saltutil.refresh_pillar I can see the code in my ext_pillar executing but after it is run if I run 'pillar.items' I do not see the contents that I expect. What could be the reason, Has anybody got an Idea?

Akilesh K

unread,
Aug 11, 2014, 6:51:05 AM8/11/14
to salt-...@googlegroups.com
It looks as if my module is imported but the ext_pillar method is not called at all.

Akilesh K

unread,
Aug 11, 2014, 8:40:44 AM8/11/14
to salt-...@googlegroups.com
Finally I realize that unlike execution modules ext pillar modules actually run on the master and not on the minion. Someone's got to mention it in the documentations.
Reply all
Reply to author
Forward
0 new messages