Skip to content

Commit 7cf7670

Browse files
author
Gabriel Monroy
committed
Merge pull request #522 from opdemand/containerize
Merge containerize into master
2 parents b85954d + 78c7696 commit 7cf7670

60 files changed

Lines changed: 1016 additions & 463 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.coveragerc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ omit =
44
*/virtualenv/*
55
*tests*
66
api/__init__.py
7+
api/docker.py
78
client/__init__.py
89
client/models.py
910
cm/__init__.py
@@ -16,6 +17,9 @@ omit =
1617
web/__init__.py
1718
web/models.py
1819
web/templatetags/__init__.py
20+
# osx library files when not running in virtualenv
21+
/Library/*
22+
/System/*
1923

2024
[report]
2125
ignore_errors = True

.gitmodules

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
[submodule "images/discovery"]
2+
path = images/discovery
3+
url = https://github.com/deis/discovery.git
4+
[submodule "images/cache"]
5+
path = images/cache
6+
url = https://github.com/deis/cache.git
7+
[submodule "images/server"]
8+
path = images/server
9+
url = https://github.com/deis/server.git
10+
[submodule "images/worker"]
11+
path = images/worker
12+
url = https://github.com/deis/worker.git
13+
[submodule "images/builder"]
14+
path = images/builder
15+
url = https://github.com/deis/builder.git
16+
[submodule "images/registry"]
17+
path = images/registry
18+
url = https://github.com/deis/registry.git
19+
[submodule "images/logger"]
20+
path = images/logger
21+
url = https://github.com/deis/logger.git
22+
[submodule "images/database"]
23+
path = images/database
24+
url = https://github.com/deis/database.git

Berksfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ cookbook 'sudo'
66
#cookbook 'deis', '~> 0.5.0'
77

88
# development cookbook
9-
cookbook 'deis', git: 'https://github.com/opdemand/deis-cookbook.git'
9+
cookbook 'deis', git: 'https://github.com/opdemand/deis-cookbook.git', branch: 'containerize'

Berksfile.lock

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,52 @@
1313
"locked_version": "0.5.0",
1414
"git": "https://github.com/opdemand/deis-cookbook.git",
1515
"ref": "e172d9f1347f9876eda626866cf0c45a3ceaea64"
16+
},
17+
"docker": {
18+
"locked_version": "0.30.0"
19+
},
20+
"git": {
21+
"locked_version": "2.9.0"
22+
},
23+
"dmg": {
24+
"locked_version": "2.1.4"
25+
},
26+
"build-essential": {
27+
"locked_version": "1.4.2"
28+
},
29+
"windows": {
30+
"locked_version": "1.12.8"
31+
},
32+
"chef_handler": {
33+
"locked_version": "1.1.4"
34+
},
35+
"runit": {
36+
"locked_version": "1.5.8"
37+
},
38+
"yum": {
39+
"locked_version": "3.0.6"
40+
},
41+
"yum-epel": {
42+
"locked_version": "0.2.0"
43+
},
44+
"golang": {
45+
"locked_version": "1.3.0"
46+
},
47+
"homebrew": {
48+
"locked_version": "1.5.4"
49+
},
50+
"lxc": {
51+
"locked_version": "1.1.8"
52+
},
53+
"dpkg_autostart": {
54+
"locked_version": "0.1.10"
55+
},
56+
"modules": {
57+
"locked_version": "0.2.0"
58+
},
59+
"sysctl": {
60+
"locked_version": "0.3.5"
61+
>>>>>>> switch to containerized cookbooks branch
1662
}
1763
}
1864
}

Gemfile.lock

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@ GEM
55
i18n (~> 0.6, >= 0.6.4)
66
multi_json (~> 1.0)
77
addressable (2.3.5)
8-
akami (1.2.0)
8+
akami (1.2.1)
99
gyoku (>= 0.4.0)
10-
nokogiri (>= 1.4.0)
11-
berkshelf (2.0.10)
10+
nokogiri
11+
berkshelf (2.0.14)
1212
activesupport (~> 3.2.0)
1313
addressable (~> 2.3.4)
1414
buff-shell_out (~> 0.1)
1515
chozo (>= 0.6.1)
16-
faraday (>= 0.8.5)
16+
faraday (~> 0.8.0)
17+
faraday (~> 0.8.5)
1718
hashie (>= 2.0.2)
1819
minitar (~> 0.5.4)
1920
rbzip2 (~> 0.2.0)
@@ -24,7 +25,7 @@ GEM
2425
buff-config (0.4.0)
2526
buff-extensions (~> 0.3)
2627
varia_model (~> 0.1)
27-
buff-extensions (0.5.0)
28+
buff-extensions (1.0.0)
2829
buff-ignore (1.1.1)
2930
buff-ruby_engine (0.1.0)
3031
buff-shell_out (0.1.1)
@@ -85,10 +86,11 @@ GEM
8586
formatador (0.2.4)
8687
gssapi (1.0.3)
8788
ffi (>= 1.0.1)
88-
gyoku (1.1.0)
89+
gyoku (1.1.1)
8990
builder (>= 2.1.2)
9091
hashie (2.0.5)
9192
highline (1.6.20)
93+
hitimes (1.2.1)
9294
httpclient (2.3.4.1)
9395
httpi (0.9.7)
9496
rack
@@ -110,9 +112,9 @@ GEM
110112
knife-windows (0.5.14)
111113
em-winrm (= 0.5.4)
112114
little-plugger (1.1.3)
113-
logging (1.8.1)
115+
logging (1.8.2)
114116
little-plugger (>= 1.1.3)
115-
multi_json (>= 1.3.6)
117+
multi_json (>= 1.8.4)
116118
mime-types (2.1)
117119
mini_portile (0.5.2)
118120
minitar (0.5.4)
@@ -122,19 +124,19 @@ GEM
122124
mixlib-config (1.1.2)
123125
mixlib-log (1.6.0)
124126
mixlib-shellout (1.3.0)
125-
multi_json (1.8.2)
127+
multi_json (1.8.4)
126128
multipart-post (1.2.0)
127-
net-http-persistent (2.9)
129+
net-http-persistent (2.9.4)
128130
net-scp (1.1.2)
129131
net-ssh (>= 2.6.5)
130-
net-ssh (2.7.0)
132+
net-ssh (2.8.0)
131133
net-ssh-gateway (1.2.0)
132134
net-ssh (>= 2.6.5)
133135
net-ssh-multi (1.1)
134136
net-ssh (>= 2.1.4)
135137
net-ssh-gateway (>= 0.99.0)
136-
nio4r (0.5.0)
137-
nokogiri (1.6.0)
138+
nio4r (1.0.0)
139+
nokogiri (1.6.1)
138140
mini_portile (~> 0.5.0)
139141
nori (1.1.5)
140142
ohai (6.20.0)
@@ -151,7 +153,7 @@ GEM
151153
rbzip2 (0.2.0)
152154
rest-client (1.6.7)
153155
mime-types (>= 1.16)
154-
retryable (1.3.3)
156+
retryable (1.3.5)
155157
ridley (1.5.3)
156158
addressable
157159
buff-config (~> 0.2)
@@ -185,9 +187,10 @@ GEM
185187
solve (0.8.2)
186188
systemu (2.5.2)
187189
thor (0.18.1)
188-
timers (1.1.0)
190+
timers (2.0.0)
191+
hitimes
189192
uuidtools (2.1.4)
190-
varia_model (0.2.0)
193+
varia_model (0.3.2)
191194
buff-extensions (~> 0.2)
192195
hashie (>= 2.0.2)
193196
wasabi (1.0.0)

Procfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
web: gunicorn_django -c gconfig.py
1+
web: gunicorn deis.wsgi -b 0.0.0.0:8000 -w 8 -n deis --log-level debug

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Deis comes with out-of-the-box support for Ruby, Python, Node.js, Java, Clojure,
1717

1818
##### Deploy anything
1919

20-
Deploy a wide range of languages and frameworks with a simple `git push` using [Heroku Buildpacks](https://devcenter.heroku.com/articles/buildpacks) or (coming soon) [Dockerfiles](http://docs.docker.io/en/latest/use/builder/). Use custom Chef layers to deploy databases, middleware and other add-on services.
20+
Deploy a wide range of languages and frameworks with a simple `git push` using [Heroku Buildpacks](https://devcenter.heroku.com/articles/buildpacks) or [Dockerfiles](http://docs.docker.io/en/latest/use/builder/). Use custom Chef layers to deploy databases, middleware and other add-on services.
2121

2222
##### Control everything
2323

@@ -60,7 +60,6 @@ Deis stands on the shoulders of leading open source technologies:
6060
* [Celery](http://www.celeryproject.org/)
6161
* [Heroku Buildpacks](https://devcenter.heroku.com/articles/buildpacks)
6262
* [Slugbuilder](https://github.com/flynn/slugbuilder) and [slugrunner](https://github.com/flynn/slugrunner)
63-
* [Gitosis](https://github.com/opdemand/gitosis)
6463

6564
## License
6665

Vagrantfile

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
1-
21
Vagrant.configure("2") do |config|
3-
config.vm.box = "deis-node"
4-
5-
# This is a preloaded Deis Ubuntu 12.04 Precise box. It's about 1GB
6-
config.vm.box_url = "https://s3-us-west-2.amazonaws.com/opdemand/deis-node.box"
2+
config.vm.box = "precise64"
73

4+
# Ubuntu 12.04.3 LTS base with 3.8 kernel (ready for Docker)
5+
config.vm.box_url = "https://oss-binaries.phusionpassenger.com/vagrant/boxes/ubuntu-12.04.3-amd64-vbox.box"
6+
87
# Avahi-daemon will broadcast the server's address as deis-controller.local
98
config.vm.host_name = "deis-controller"
109

1110
# IP will be associated to 'deis-controller.local' using avahi-daemon
1211
config.vm.network :private_network, ip: "192.168.61.100"
13-
12+
1413
# The Deis Controller requires at least 2G of RAM to install.
1514
config.vm.provider :virtualbox do |vb|
1615
vb.customize ["modifyvm", :id, "--memory", "2048"]
@@ -23,12 +22,41 @@ Vagrant.configure("2") do |config|
2322
nodes_dir = File.dirname(__FILE__) + '/contrib/vagrant/nodes'
2423

2524
config.vm.provision :shell, inline: <<-SCRIPT
25+
# install latest stable chef for subsequent provision blocks
26+
sudo apt-get install -yq curl
27+
chef-client -v | grep 10.14.2 && curl -L https://www.opscode.com/chef/install.sh | sudo bash
28+
# install 'etcd' gem using the vagrant chef runtime
29+
sudo /opt/chef/embedded/bin/gem install etcd --no-ri --no-rdoc
2630
# Avahi-daemon broadcasts the machine's hostname to local DNS.
2731
# Therefore 'deis-controller.local' in this case.
28-
sudo service avahi-daemon restart
32+
sudo apt-get install -yq avahi-daemon
2933
# Make a record of where the deis code base is on the host machine
3034
echo "#{nodes_dir}" > /home/vagrant/.host_nodes_dir
3135
SCRIPT
36+
37+
# load chef config from ~/.chef/knife.rb (requires `vagrant plugin install chef`)
38+
Chef::Config.from_file(File.join(ENV['HOME'], '.chef', 'knife.rb'))
39+
40+
config.vm.provision "chef_client" do |chef|
41+
chef.chef_server_url = Chef::Config[:chef_server_url]
42+
chef.client_key_path = Chef::Config[:client_key]
43+
chef.validation_client_name = Chef::Config[:validation_client_name]
44+
chef.validation_key_path = Chef::Config[:validation_key]
45+
chef.log_level = Chef::Config[:log_level]
46+
# TODO: replace with in-recipe public_ip lookup that handles vagrant/ec2/metal
47+
chef.json = {
48+
"deis" => {
49+
"public_ip" => "192.168.61.100",
50+
"dev" => {
51+
"mode" => true,
52+
"source" => "/vagrant"
53+
}
54+
}
55+
}
56+
# define the run list
57+
chef.add_recipe 'deis::controller'
58+
end
59+
3260
end
3361

3462
# If you want to do some funky custom stuff to your box, but don't want those things tracked by git,

0 commit comments

Comments
 (0)