/usr/lib/python2.6/site-packages/salt/runners/pillar.pypillarrunner模块提供一些在Master端与Pillar编译器交互的函数返回指定minion的pillar的编译top数据,如果没有指定minion,就使用第一个找到的miniondefshow_top(minion=None,saltenv=‘base‘):
‘‘‘
Returnsthecompiled..
分类:
其他好文 时间:
2015-05-29 16:04:42
阅读次数:
204
/usr/lib/python2.6/site-packages/salt/runners/cache.pycache模块返回minion端缓存的数据返回目标minion缓存的grains数据defgrains(tgt=None,expr_form=‘glob‘,**kwargs):
‘‘‘
Returncachedgrainsofthetargetedminions
CLIExample:
..code-block::bash
salt-runcache.grai..
分类:
系统相关 时间:
2015-05-29 15:55:49
阅读次数:
245
SaltStack的eventsystem即事件系统发送事件eventsystem包括两个主要的组件:eventsocket用来发布事件event库用来监听事件并发送事件参考文章:http://docs.saltstack.com/en/2014.7/topics/event/index.html
分类:
其他好文 时间:
2015-05-29 12:16:47
阅读次数:
119
Saltrunnersareconvenienceapplicationsexecutedwiththesalt-runcommand.Saltrunners是在Master端执行而不是在minion端执行runner模块和excution模块工作方式一样。所有可以使用的runner模块都放到runners目录下参考文章:http://docs.saltstack.com/en/2014.7/ref/runners/ind..
分类:
其他好文 时间:
2015-05-29 12:13:07
阅读次数:
141
/usr/lib/python2.6/site-packages/salt/runners/jobs.pyjobsrunner模块用于方便管理正在运行或者处于活动状态的job返回所有正在运行的job的报告defactive():
‘‘‘
Returnareportonallactivelyrunningjobsfromajobidcentric
perspective
CLIExample:
..code-block::bash
salt..
分类:
其他好文 时间:
2015-05-29 12:12:18
阅读次数:
199
Salt从0.11.0版本开始引入ReactorSystem。EventSystemTheeventsystemisalocalZeroMQPUBinterfacewhichfiressaltevents.ThiseventbusisanopensystemusedforsendinginformationnotifyingSaltandothersystemsaboutoperations.ReactorSLSfilesandeventtagsareassociatedinthemaster..
分类:
其他好文 时间:
2015-05-28 18:21:07
阅读次数:
173
/usr/lib/python2.6/site-packages/salt/modules/cmdmod.pycmdmod模块用于执行一些命令行‘‘
Amoduleforshellingout
Keepinmindthatthismoduleisinsecure,inthatitcangivewhomeverhas
accesstothemasterrootexecutionaccesstoallsaltminions.
‘‘‘#Importpythonlibs
importtime
..
分类:
其他好文 时间:
2015-05-28 14:17:59
阅读次数:
278
下面是我多年整理并使用多少的Shell 分享给大家。说起自动化运维很多人会谈到 puppet,?ansible,saltstack 这些工具我都使用了,最终都放弃了。这些工具前期配置太耗时间,扩展也不方便,适合傻瓜化运维,对于有1...
分类:
系统相关 时间:
2015-05-27 17:33:20
阅读次数:
196
/usr/lib/python2.6/site-packages/salt/modules/pillar.pydefget(key,default=‘‘,merge=False,delimiter=‘:‘):
‘‘‘
..versionadded::0.14
Attempttoretrievethenamedvaluefrompillar,ifthenamedvalueisnot
availablereturnthepasseddefault.Thedefaultreturnisanemptystring...
分类:
其他好文 时间:
2015-05-27 16:02:05
阅读次数:
171