Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 19 lines (13 sloc) 0.502 kb
37c9d7a @ericholscher Added a super basic chef config.
authored
1 from fabric.api import env, local, sudo
2 env.user = 'root'
3 env.hosts = ['204.232.205.196']
4
e56a473 @ericholscher Fix chef path.
authored
5 env.chef_executable = '/var/lib/gems/1.8/bin/chef-solo'
a44fe40 @ericholscher Make non-chef-version-dependant bin path.
authored
6
37c9d7a @ericholscher Added a super basic chef config.
authored
7
8 def install_chef():
9 sudo('apt-get update', pty=True)
10 sudo('apt-get install -y git-core rubygems ruby ruby-dev', pty=True)
a44fe40 @ericholscher Make non-chef-version-dependant bin path.
authored
11 sudo('gem install chef', pty=True)
37c9d7a @ericholscher Added a super basic chef config.
authored
12
13 def sync_config():
14 local('rsync -av . %s@%s:/etc/chef' % (env.user, env.hosts[0]))
15
16 def update():
17 sync_config()
18 sudo('cd /etc/chef && %s' % env.chef_executable, pty=True)
Something went wrong with that request. Please try again.