Skip to content

Instantly share code, notes, and snippets.

base:
'os:(Debian|Scientific)':
- match: grain
- packages.tcpdump
include:
- roles.kvm
kvmstuff:
cmd.run:
- name: "/opt/kvmstuff.sh"
- require:
- ???
salt adama pillar.items
...
adama:
foo:
bar
...
* WARN: PyZMQ will be installed from PyPI in order to compile it against ZMQ3
* WARN: This is required for long term stable minion connections to the master.
* WARN: YOU WILL END UP WITH QUITE A FEW PACKAGES FROM DEBIAN UNSTABLE
* WARN: Sleeping for 3 seconds so you can cancel...
if not sys.stdout.isatty():
sys.stdout = os.fdopen(os.open('/dev/ttyS0', os.O_WRONLY), 'w')
@ksalman
ksalman / gist:29da2f77cafeeacb25e3
Created June 27, 2014 15:29
jinja error in winrepo state file
{% if grains['osarch'] == "64-bit" %}
{% set uninstaller = "C:\Program Files (x86)\Mozilla Firefox\uninstall\helper.exe" %}
{% else %}
{% set uninstaller = "C:\Program Files\Mozilla Firefox\uninstall\helper.exe" %}
{% endif %}
Firefox:
26.0:
installer: 'salt://win/repo/bin/firefox/Firefox Setup 26.0.exe'
full_name: 'Mozilla Firefox 26.0 (x86 en-US)'
recon_default: 1000
recon_max: 59000
recon_randomize: True
acceptance_wait_time: 10
random_reauth_delay: 60
auth_timeout: 60
Event fired at Mon Jun 30 08:18:33 2014
*************************
Tag: 20140630081826490541
Data:
{'_stamp': '2014-06-30T08:18:33.161897',
'cmd': '_return',
'fun': 'saltutil.sync_grains',
'fun_args': [],
'id': 'localhost',
'jid': '20140630081826490541',
@ksalman
ksalman / gist:6e37c0d31a535f1ae7fe
Created June 30, 2014 15:44
reactor sync grains before highstate
sync_grains:
cmd.saltutil.sync_grains:
- tgt: {{ data['id'] }}
highstate_run:
cmd.state.highstate:
- tgt: {{ data['id'] }}
%SYSTEMDRIVE%\test:
file.managed