ventriloquist 0.3.2 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -1
- data/CHANGELOG.md +47 -2
- data/Gemfile +2 -1
- data/Gemfile.lock +36 -28
- data/README.md +116 -41
- data/base_box/README.md +3 -0
- data/base_box/Vagrantfile +66 -0
- data/development/Vagrantfile +32 -11
- data/lib/ventriloquist/cap/platforms.rb +55 -0
- data/lib/ventriloquist/cap/{debian → platforms/debian}/elixir_install.rb +1 -0
- data/lib/ventriloquist/cap/{debian → platforms/debian}/erlang_install.rb +0 -0
- data/lib/ventriloquist/cap/{debian → platforms/debian}/go_install.rb +1 -1
- data/lib/ventriloquist/cap/{debian → platforms/debian}/phantomjs_install.rb +1 -1
- data/lib/ventriloquist/cap/{debian → platforms/debian}/python.rb +1 -0
- data/lib/ventriloquist/cap/{linux → platforms/linux}/nvm_install.rb +0 -0
- data/lib/ventriloquist/cap/{linux → platforms/linux}/nvm_install_nodejs.rb +0 -0
- data/lib/ventriloquist/cap/platforms/linux/rvm_install.rb +17 -0
- data/lib/ventriloquist/cap/{linux → platforms/linux}/rvm_install_ruby.rb +2 -3
- data/lib/ventriloquist/cap/services.rb +40 -0
- data/lib/ventriloquist/cap/{debian → services/debian}/mysql_install_client.rb +1 -1
- data/lib/ventriloquist/cap/{debian → services/debian}/mysql_install_headers.rb +1 -1
- data/lib/ventriloquist/cap/{debian → services/debian}/pg_install_client.rb +1 -1
- data/lib/ventriloquist/cap/{debian → services/debian}/pg_install_headers.rb +1 -1
- data/lib/ventriloquist/cap/{debian → services/debian}/ventriloquist_containers_upstart.rb +0 -0
- data/lib/ventriloquist/cap/{linux → services/linux}/mysql_configure_client.rb +0 -0
- data/lib/ventriloquist/cap/{linux → services/linux}/pg_export_pghost.rb +0 -0
- data/lib/ventriloquist/cap/utils.rb +40 -0
- data/lib/ventriloquist/cap/utils/debian/git_install.rb +13 -0
- data/lib/ventriloquist/cap/utils/debian/install_build_tools.rb +13 -0
- data/lib/ventriloquist/cap/utils/debian/install_packages.rb +47 -0
- data/lib/ventriloquist/cap/utils/debian/mercurial_install.rb +13 -0
- data/lib/ventriloquist/cap/utils/linux/download.rb +39 -0
- data/lib/ventriloquist/cap/{linux → utils/linux}/make.rb +0 -0
- data/lib/ventriloquist/cap/{linux → utils/linux}/untar.rb +0 -0
- data/lib/ventriloquist/config.rb +6 -3
- data/lib/ventriloquist/platforms/elixir.rb +1 -1
- data/lib/ventriloquist/platforms/go.rb +1 -1
- data/lib/ventriloquist/platforms/nodejs.rb +1 -0
- data/lib/ventriloquist/platforms/phantomjs.rb +1 -1
- data/lib/ventriloquist/platforms/ruby.rb +1 -0
- data/lib/ventriloquist/plugin.rb +3 -114
- data/lib/ventriloquist/provisioner.rb +12 -1
- data/lib/ventriloquist/service.rb +14 -7
- data/lib/ventriloquist/services/elastic_search.rb +12 -0
- data/lib/ventriloquist/services/mail_catcher.rb +12 -0
- data/lib/ventriloquist/services/memcached.rb +12 -0
- data/lib/ventriloquist/services/mysql.rb +5 -0
- data/lib/ventriloquist/services/postgresql.rb +5 -0
- data/lib/ventriloquist/services/redis.rb +12 -6
- data/lib/ventriloquist/services/rethink_db.rb +16 -0
- data/lib/ventriloquist/services_builder.rb +14 -5
- data/lib/ventriloquist/version.rb +1 -1
- data/locales/en.yml +6 -1
- data/services/base/Dockerfile +8 -7
- data/services/build-all.sh +6 -3
- data/services/elasticsearch/Dockerfile +6 -7
- data/services/mailcatcher/Dockerfile +3 -6
- data/services/memcached/Dockerfile +11 -12
- data/services/mysql/5.5/Dockerfile +17 -0
- data/services/mysql/{config → 5.5/config}/bin/add-mysql-user +0 -5
- data/services/mysql/5.6/Dockerfile +32 -0
- data/services/mysql/5.6/config/bin/add-mysql-user +15 -0
- data/services/mysql/5.6/config/etc/my.cnf +129 -0
- data/services/openjdk7/Dockerfile +1 -5
- data/services/postgresql/9.1/Dockerfile +5 -10
- data/services/postgresql/9.2/Dockerfile +7 -6
- data/services/postgresql/9.3/Dockerfile +16 -0
- data/services/postgresql/9.3/config/bin/prepare-postgres +25 -0
- data/services/postgresql/9.3/config/bin/start-postgres +6 -0
- data/services/postgresql/9.3/config/etc/postgresql/9.3/main/postgresql.conf +591 -0
- data/services/redis/Dockerfile +10 -6
- data/services/rethinkdb/Dockerfile +17 -0
- data/spec/unit/service_spec.rb +22 -12
- data/spec/unit/services_builder_spec.rb +26 -8
- data/ventriloquist.gemspec +1 -1
- metadata +46 -28
- data/lib/ventriloquist/cap/debian/git_install.rb +0 -18
- data/lib/ventriloquist/cap/debian/install_build_tools.rb +0 -18
- data/lib/ventriloquist/cap/debian/mercurial_install.rb +0 -18
- data/lib/ventriloquist/cap/linux/download.rb +0 -26
- data/lib/ventriloquist/cap/linux/rvm_install.rb +0 -17
- data/services/mysql/Dockerfile +0 -20
data/services/redis/Dockerfile
CHANGED
@@ -1,11 +1,15 @@
|
|
1
|
-
# Redis Server
|
2
|
-
#
|
3
|
-
# VERSION 0.0.1
|
1
|
+
# Redis Server
|
4
2
|
|
5
3
|
FROM fgrehm/ventriloquist-base
|
6
|
-
MAINTAINER Fabio Rehm "fgrehm@gmail.com"
|
7
4
|
|
8
|
-
|
5
|
+
# Make sure to update lib/ventriloquist/services/redis.rb if the version gets bumped
|
6
|
+
RUN wget -q http://download.redis.io/releases/redis-2.8.2.tar.gz -O /tmp/redis.tar.gz && \
|
7
|
+
cd /tmp && \
|
8
|
+
tar xvfz redis.tar.gz && \
|
9
|
+
cd redis-2.8.2 && \
|
10
|
+
make redis-server && \
|
11
|
+
mv src/redis-server /usr/bin && \
|
12
|
+
cd .. && rm -rf redis*
|
9
13
|
|
10
|
-
EXPOSE 6379
|
14
|
+
EXPOSE 6379
|
11
15
|
CMD ["/usr/bin/redis-server"]
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# Dockerfile for Rethinkdb
|
2
|
+
# Based on https://github.com/crosbymichael/Dockerfiles/blob/master/rethinkdb/Dockerfile
|
3
|
+
|
4
|
+
FROM fgrehm/ventriloquist-base
|
5
|
+
|
6
|
+
RUN add-apt-repository ppa:rethinkdb/ppa && \
|
7
|
+
apt-get update && \
|
8
|
+
apt-get install -y rethinkdb && \
|
9
|
+
apt-get clean
|
10
|
+
|
11
|
+
# create the /rethinkdb_data dir structure
|
12
|
+
RUN /usr/bin/rethinkdb create
|
13
|
+
|
14
|
+
# Rethinkdb process, cluster, and webui
|
15
|
+
EXPOSE 28015 29015 8080
|
16
|
+
|
17
|
+
CMD ["/usr/bin/rethinkdb", "--bind", "all"]
|
data/spec/unit/service_spec.rb
CHANGED
@@ -8,7 +8,7 @@ require 'ventriloquist/service'
|
|
8
8
|
describe VagrantPlugins::Ventriloquist::Service do
|
9
9
|
verify_contract(:service)
|
10
10
|
|
11
|
-
fake(:docker_client)
|
11
|
+
let(:docker_client) { fake(:docker_client, container_running?: false) }
|
12
12
|
fake(:communicator) { VagrantPlugins::CommunicatorSSH::Communicator }
|
13
13
|
fake(:ui) { Vagrant::UI::Interface }
|
14
14
|
let(:env) { fake(:environment, ui: ui) }
|
@@ -21,20 +21,30 @@ describe VagrantPlugins::Ventriloquist::Service do
|
|
21
21
|
|
22
22
|
before { subject.provision(machine) }
|
23
23
|
|
24
|
-
|
25
|
-
|
26
|
-
|
24
|
+
context 'given the container has not been created' do
|
25
|
+
it 'runs the configured container' do
|
26
|
+
expect(docker_client).to have_received.run_container(service_conf)
|
27
|
+
end
|
27
28
|
|
28
|
-
|
29
|
-
|
30
|
-
|
29
|
+
it 'creates a directory for keeping container id files' do
|
30
|
+
expect(communicator).to have_received.sudo('mkdir -p /var/lib/ventriloquist/cids')
|
31
|
+
end
|
31
32
|
|
32
|
-
|
33
|
-
|
34
|
-
|
33
|
+
it 'assigns a cidfile based on the service name' do
|
34
|
+
expected_cidfile = "#{described_class::CONTAINER_IDS_PATH}/#{service_name}"
|
35
|
+
expect(docker_client).to have_received.run_container(with{|c| c[:cidfile] == expected_cidfile})
|
36
|
+
end
|
37
|
+
|
38
|
+
it 'sets dns to 127.0.0.1 to reduce latency' do
|
39
|
+
expect(docker_client).to have_received.run_container(with{|c| c[:dns] == "127.0.0.1"})
|
40
|
+
end
|
35
41
|
end
|
36
42
|
|
37
|
-
|
38
|
-
|
43
|
+
context 'given the container has already been created' do
|
44
|
+
let(:docker_client) { fake(:docker_client, container_running?: true) }
|
45
|
+
|
46
|
+
it 'does not attempt to run container' do
|
47
|
+
expect(docker_client).to_not have_received.run_container(any_args)
|
48
|
+
end
|
39
49
|
end
|
40
50
|
end
|
@@ -11,22 +11,36 @@ describe VagrantPlugins::Ventriloquist::ServicesBuilder do
|
|
11
11
|
fake(:docker_client)
|
12
12
|
|
13
13
|
let(:pg_cfg) { {image: 'user/pg', tag: '9.2'} }
|
14
|
-
let(:svcs_configs) { [{pg: pg_cfg}, ['some-service'], 'mysql:1.2'] }
|
15
14
|
let(:custom_mapping) { {'mysql' => custom_service} }
|
16
15
|
let(:custom_service) { Class.new(Service) }
|
16
|
+
let(:svcs_configs) { [
|
17
|
+
{pg: pg_cfg},
|
18
|
+
['some-service'],
|
19
|
+
'mysql:1.2',
|
20
|
+
{name: {type: 'mysql'}},
|
21
|
+
{api_db: {vimage: 'mysql'}}
|
22
|
+
] }
|
17
23
|
|
18
|
-
let(:services)
|
19
|
-
let(:pg)
|
20
|
-
let(:other)
|
21
|
-
let(:mysql)
|
24
|
+
let(:services) { described_class.new(svcs_configs, custom_mapping).build(docker_client) }
|
25
|
+
let(:pg) { services[0] }
|
26
|
+
let(:other) { services[1] }
|
27
|
+
let(:mysql) { services[2] }
|
28
|
+
let(:mysql_2) { services[3] }
|
29
|
+
let(:vimage_ex) { services[4] }
|
22
30
|
|
23
31
|
it 'builds a list of service objects' do
|
24
|
-
expect(services).to have(
|
25
|
-
expect(
|
26
|
-
|
32
|
+
expect(services).to have(5).items
|
33
|
+
expect(services.all?{|s| s.is_a?(Service)}).to be_true
|
34
|
+
end
|
35
|
+
|
36
|
+
it 'uses container name as type' do
|
27
37
|
expect(mysql).to be_a(custom_service)
|
28
38
|
end
|
29
39
|
|
40
|
+
it 'looks up service class by type name' do
|
41
|
+
expect(mysql_2).to be_a(custom_service)
|
42
|
+
end
|
43
|
+
|
30
44
|
it 'sets the docker client for services' do
|
31
45
|
expect(pg.docker_client).to eq(docker_client)
|
32
46
|
end
|
@@ -47,6 +61,10 @@ describe VagrantPlugins::Ventriloquist::ServicesBuilder do
|
|
47
61
|
expect(mysql.config[:image]).to eq('fgrehm/ventriloquist-mysql:1.2')
|
48
62
|
end
|
49
63
|
|
64
|
+
it 'expands vimage' do
|
65
|
+
expect(vimage_ex.config[:image]).to eq('fgrehm/ventriloquist-mysql:latest')
|
66
|
+
end
|
67
|
+
|
50
68
|
it 'sets the service name' do
|
51
69
|
expect(pg.name).to eq('pg')
|
52
70
|
expect(mysql.name).to eq('mysql')
|
data/ventriloquist.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ventriloquist
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fabio Rehm
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-12-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: vocker
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ~>
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.4.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - ~>
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.
|
26
|
+
version: 0.4.0
|
27
27
|
description: Vagrant development environments made easy
|
28
28
|
email:
|
29
29
|
- fgrehm@gmail.com
|
@@ -41,30 +41,36 @@ files:
|
|
41
41
|
- LICENSE.txt
|
42
42
|
- README.md
|
43
43
|
- Rakefile
|
44
|
+
- base_box/README.md
|
45
|
+
- base_box/Vagrantfile
|
44
46
|
- development/Vagrantfile
|
45
47
|
- lib/ventriloquist.rb
|
46
|
-
- lib/ventriloquist/cap/
|
47
|
-
- lib/ventriloquist/cap/debian/
|
48
|
-
- lib/ventriloquist/cap/debian/
|
49
|
-
- lib/ventriloquist/cap/debian/go_install.rb
|
50
|
-
- lib/ventriloquist/cap/debian/
|
51
|
-
- lib/ventriloquist/cap/debian/
|
52
|
-
- lib/ventriloquist/cap/
|
53
|
-
- lib/ventriloquist/cap/
|
54
|
-
- lib/ventriloquist/cap/
|
55
|
-
- lib/ventriloquist/cap/
|
56
|
-
- lib/ventriloquist/cap/
|
57
|
-
- lib/ventriloquist/cap/debian/
|
58
|
-
- lib/ventriloquist/cap/debian/
|
59
|
-
- lib/ventriloquist/cap/
|
60
|
-
- lib/ventriloquist/cap/
|
61
|
-
- lib/ventriloquist/cap/
|
62
|
-
- lib/ventriloquist/cap/linux/
|
63
|
-
- lib/ventriloquist/cap/linux/
|
64
|
-
- lib/ventriloquist/cap/
|
65
|
-
- lib/ventriloquist/cap/
|
66
|
-
- lib/ventriloquist/cap/
|
67
|
-
- lib/ventriloquist/cap/
|
48
|
+
- lib/ventriloquist/cap/platforms.rb
|
49
|
+
- lib/ventriloquist/cap/platforms/debian/elixir_install.rb
|
50
|
+
- lib/ventriloquist/cap/platforms/debian/erlang_install.rb
|
51
|
+
- lib/ventriloquist/cap/platforms/debian/go_install.rb
|
52
|
+
- lib/ventriloquist/cap/platforms/debian/phantomjs_install.rb
|
53
|
+
- lib/ventriloquist/cap/platforms/debian/python.rb
|
54
|
+
- lib/ventriloquist/cap/platforms/linux/nvm_install.rb
|
55
|
+
- lib/ventriloquist/cap/platforms/linux/nvm_install_nodejs.rb
|
56
|
+
- lib/ventriloquist/cap/platforms/linux/rvm_install.rb
|
57
|
+
- lib/ventriloquist/cap/platforms/linux/rvm_install_ruby.rb
|
58
|
+
- lib/ventriloquist/cap/services.rb
|
59
|
+
- lib/ventriloquist/cap/services/debian/mysql_install_client.rb
|
60
|
+
- lib/ventriloquist/cap/services/debian/mysql_install_headers.rb
|
61
|
+
- lib/ventriloquist/cap/services/debian/pg_install_client.rb
|
62
|
+
- lib/ventriloquist/cap/services/debian/pg_install_headers.rb
|
63
|
+
- lib/ventriloquist/cap/services/debian/ventriloquist_containers_upstart.rb
|
64
|
+
- lib/ventriloquist/cap/services/linux/mysql_configure_client.rb
|
65
|
+
- lib/ventriloquist/cap/services/linux/pg_export_pghost.rb
|
66
|
+
- lib/ventriloquist/cap/utils.rb
|
67
|
+
- lib/ventriloquist/cap/utils/debian/git_install.rb
|
68
|
+
- lib/ventriloquist/cap/utils/debian/install_build_tools.rb
|
69
|
+
- lib/ventriloquist/cap/utils/debian/install_packages.rb
|
70
|
+
- lib/ventriloquist/cap/utils/debian/mercurial_install.rb
|
71
|
+
- lib/ventriloquist/cap/utils/linux/download.rb
|
72
|
+
- lib/ventriloquist/cap/utils/linux/make.rb
|
73
|
+
- lib/ventriloquist/cap/utils/linux/untar.rb
|
68
74
|
- lib/ventriloquist/config.rb
|
69
75
|
- lib/ventriloquist/errors.rb
|
70
76
|
- lib/ventriloquist/platform.rb
|
@@ -79,9 +85,13 @@ files:
|
|
79
85
|
- lib/ventriloquist/plugin.rb
|
80
86
|
- lib/ventriloquist/provisioner.rb
|
81
87
|
- lib/ventriloquist/service.rb
|
88
|
+
- lib/ventriloquist/services/elastic_search.rb
|
89
|
+
- lib/ventriloquist/services/mail_catcher.rb
|
90
|
+
- lib/ventriloquist/services/memcached.rb
|
82
91
|
- lib/ventriloquist/services/mysql.rb
|
83
92
|
- lib/ventriloquist/services/postgresql.rb
|
84
93
|
- lib/ventriloquist/services/redis.rb
|
94
|
+
- lib/ventriloquist/services/rethink_db.rb
|
85
95
|
- lib/ventriloquist/services_builder.rb
|
86
96
|
- lib/ventriloquist/version.rb
|
87
97
|
- locales/en.yml
|
@@ -90,8 +100,11 @@ files:
|
|
90
100
|
- services/elasticsearch/Dockerfile
|
91
101
|
- services/mailcatcher/Dockerfile
|
92
102
|
- services/memcached/Dockerfile
|
93
|
-
- services/mysql/Dockerfile
|
94
|
-
- services/mysql/config/bin/add-mysql-user
|
103
|
+
- services/mysql/5.5/Dockerfile
|
104
|
+
- services/mysql/5.5/config/bin/add-mysql-user
|
105
|
+
- services/mysql/5.6/Dockerfile
|
106
|
+
- services/mysql/5.6/config/bin/add-mysql-user
|
107
|
+
- services/mysql/5.6/config/etc/my.cnf
|
95
108
|
- services/openjdk7/Dockerfile
|
96
109
|
- services/postgresql/9.1/Dockerfile
|
97
110
|
- services/postgresql/9.1/config/bin/prepare-postgres
|
@@ -101,7 +114,12 @@ files:
|
|
101
114
|
- services/postgresql/9.2/config/bin/prepare-postgres
|
102
115
|
- services/postgresql/9.2/config/bin/start-postgres
|
103
116
|
- services/postgresql/9.2/config/etc/postgresql/9.2/main/postgresql.conf
|
117
|
+
- services/postgresql/9.3/Dockerfile
|
118
|
+
- services/postgresql/9.3/config/bin/prepare-postgres
|
119
|
+
- services/postgresql/9.3/config/bin/start-postgres
|
120
|
+
- services/postgresql/9.3/config/etc/postgresql/9.3/main/postgresql.conf
|
104
121
|
- services/redis/Dockerfile
|
122
|
+
- services/rethinkdb/Dockerfile
|
105
123
|
- spec/spec_helper.rb
|
106
124
|
- spec/unit/platforms_builder_spec.rb
|
107
125
|
- spec/unit/service_spec.rb
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module VagrantPlugins
|
2
|
-
module Ventriloquist
|
3
|
-
module Cap
|
4
|
-
module Debian
|
5
|
-
module GitInstall
|
6
|
-
def self.git_install(machine)
|
7
|
-
machine.communicate.tap do |comm|
|
8
|
-
if ! comm.test('which git > /dev/null')
|
9
|
-
machine.env.ui.info('Installing git')
|
10
|
-
comm.sudo('apt-get install -y git')
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module VagrantPlugins
|
2
|
-
module Ventriloquist
|
3
|
-
module Cap
|
4
|
-
module Debian
|
5
|
-
module InstallBuildTools
|
6
|
-
def self.install_build_tools(machine)
|
7
|
-
machine.communicate.tap do |comm|
|
8
|
-
if ! comm.test('dpkg -l | grep build-essential')
|
9
|
-
machine.env.ui.info('Installing build tools')
|
10
|
-
comm.sudo('apt-get install -y build-essential')
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module VagrantPlugins
|
2
|
-
module Ventriloquist
|
3
|
-
module Cap
|
4
|
-
module Debian
|
5
|
-
module MercurialInstall
|
6
|
-
def self.mercurial_install(machine)
|
7
|
-
machine.communicate.tap do |comm|
|
8
|
-
if ! comm.test('which hg > /dev/null')
|
9
|
-
machine.env.ui.info('Installing mercurial')
|
10
|
-
comm.sudo('apt-get install -y mercurial')
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
@@ -1,26 +0,0 @@
|
|
1
|
-
module VagrantPlugins
|
2
|
-
module Ventriloquist
|
3
|
-
module Cap
|
4
|
-
module Linux
|
5
|
-
module Download
|
6
|
-
# FIXME: Use vagrant downloader and upload to guest machine
|
7
|
-
def self.download(machine, src, destination)
|
8
|
-
machine.communicate.tap do |comm|
|
9
|
-
if comm.test('which wget')
|
10
|
-
machine.env.ui.info("Downloading #{src} to #{destination}")
|
11
|
-
comm.execute("wget #{src} -O #{destination}")
|
12
|
-
|
13
|
-
elsif comm.test('which curl')
|
14
|
-
machine.env.ui.info("Downloading #{src} to #{destination}")
|
15
|
-
comm.execute("curl #{src} -o #{destination}")
|
16
|
-
|
17
|
-
else
|
18
|
-
raise 'Unable to download file for guest VM!'
|
19
|
-
end
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
@@ -1,17 +0,0 @@
|
|
1
|
-
module VagrantPlugins
|
2
|
-
module Ventriloquist
|
3
|
-
module Cap
|
4
|
-
module Linux
|
5
|
-
module RvmInstall
|
6
|
-
def self.rvm_install(machine)
|
7
|
-
if ! machine.communicate.test('test -d $HOME/.rvm')
|
8
|
-
machine.env.ui.info('Installing RVM')
|
9
|
-
machine.communicate.execute('\curl -L https://get.rvm.io | bash -s stable --autolibs=enabled --ignore-dotfiles')
|
10
|
-
machine.communicate.execute("echo 'source $HOME/.rvm/scripts/rvm' >> ~/.profile")
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
data/services/mysql/Dockerfile
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
# MySQL 5.5
|
2
|
-
#
|
3
|
-
# VERSION 0.0.1
|
4
|
-
|
5
|
-
FROM fgrehm/ventriloquist-base
|
6
|
-
MAINTAINER Fabio Rehm "fgrehm@gmail.com"
|
7
|
-
|
8
|
-
# prevent apt from starting mysql right after the installation
|
9
|
-
RUN echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d; chmod +x /usr/sbin/policy-rc.d
|
10
|
-
|
11
|
-
RUN apt-get -q -y install mysql-server-5.5 && apt-get clean
|
12
|
-
|
13
|
-
# allow autostart again
|
14
|
-
RUN rm /usr/sbin/policy-rc.d
|
15
|
-
|
16
|
-
ADD config /
|
17
|
-
RUN /bin/add-mysql-user vagrant vagrant
|
18
|
-
|
19
|
-
EXPOSE 3306:3306
|
20
|
-
CMD ["/usr/sbin/mysqld"]
|