Skip to content

Instantly share code, notes, and snippets.

View teburd's full-sized avatar

Tom Burdick teburd

View GitHub Profile
@teburd
teburd / top.sls
Created June 20, 2013 16:48
roles not working
base:
'*':
- openssh
- vim
- zsh
- git
'roles:development':
- postgresql
- redis
- memcached
@teburd
teburd / init.sls
Created June 20, 2013 17:26
no installing pecl
php:¬
pkg.installed:¬
- pkgs:¬
- php-fpm¬
- php-memcached¬
- php-pgsql¬
- php-pear¬
- php-apc¬
- xdebug¬
¬
@teburd
teburd / whatevs
Last active December 18, 2015 18:19
[vagrant@vagrant salt]$ sudo salt-call state.highstate
[INFO ] Loaded configuration file: /etc/salt/minion
[INFO ] Executing command 'ps -efH' in directory '/root'
[INFO ] Loading fresh modules for state activity
[INFO ] Creating module dir '/var/cache/salt/minion/extmods/modules'
[INFO ] Syncing modules for environment 'base'
[INFO ] Loading cache from salt://_modules, for base)
[INFO ] Caching directory '_modules' for environment 'base'
[INFO ] Creating module dir '/var/cache/salt/minion/extmods/states'
[INFO ] Syncing states for environment 'base'
@teburd
teburd / postgresql.sls
Last active December 18, 2015 19:19
postgres
postgresql:
pkg.installed:
- pkgs:
- postgresql
- postgis
cmd.run:
- cwd: /
- user: root
- name: mkdir -p /var/lib/postgres/data && chown -R postgres:postgres /var/lib/postgres && su -c "initdb -D /var/lib/postgres/data" -l postgres
- unless: stat /var/lib/postgres/data/postgresql.conf
---
- hosts: all
tasks:
- name: Install Packages
action: yum pkg=$item state=latest
with_items:
- zsh
- vim-enhanced
- git
- htop
@teburd
teburd / weird
Created July 5, 2013 14:50
weird
PLAY [all] ********************************************************************
GATHERING FACTS ***************************************************************
ok: [192.168.1.100]
ok: [db-100-node.example.com]
ok: [green.example.com]
ok: [www004.example.com]
ok: [192.168.1.110]
ok: [beta.example.org]
ok: [db01.intranet.mydomain.net]
# This is the default ansible 'hosts' file.
#
# It should live in /etc/ansible/hosts
#
# - Comments begin with the '#' character
# - Blank lines are ignored
# - Groups of hosts are delimited by [header] elements
# - You can enter hostnames or ip addresses
# - A hostname/ip can be a member of multiple groups
Bringing machine 'default' up with 'virtualbox' provider...
[default] Setting the name of the VM...
[default] Clearing any previously set forwarded ports...
[default] Creating shared folders metadata...
[default] Clearing any previously set network interfaces...
[default] Preparing network interfaces based on configuration...
[default] Forwarding ports...
[default] -- 22 => 2222 (adapter 1)
[default] Booting VM...
[default] Waiting for VM to boot. This can take a few minutes.
[vagrant@localhost ~]$ systemctl status redis
redis.service - A persistent key-value database
Loaded: loaded (/usr/lib/systemd/system/redis.service; disabled)
Active: inactive (dead)
---
- hosts: localhost
connection: local
tasks:
- name: Install Packages
action: yum pkg=$item state=latest
with_items:
- zsh
- vim-enhanced
- git