docker-builder 0.1.16 → 0.1.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e57eca5b3bab3d219faf98f1345abe6c3b74ddcf
4
- data.tar.gz: f8339d5d42374eb407ba8fc8cfaa39c459dadefa
3
+ metadata.gz: e3489d688b9cf4c1ed021f3c0c195cdb7e0b3c80
4
+ data.tar.gz: 748dc94c710a99c4ee0d2cd7a15a38c5f104cf64
5
5
  SHA512:
6
- metadata.gz: 2c65dce204052633492f6abe6af1348a0c6fa2e71bf0017e3929197e0fdb1b7ec7a9a2664946930d5b48a478316f448198057b950eda913d67d9f732845e7e49
7
- data.tar.gz: b1dc10166f2f5bfa8a8ba221c7fcb56eb8abf5e4f78df8a563365f0348ab5a90835704b3629fc72c29d23402c686cdc287557fe94d172070b46163d5cc858fba
6
+ metadata.gz: ee440905b5bbb0b51246670d98b16c58a3d79b27f1c3f77079498b9525084676688b3f5749a6d472d20b921d770704d8313da7dcf6148fa7a2aaf4a412fb3e26
7
+ data.tar.gz: 262a8d91c32767d6386a404358291fd4ba3d2d15a7d2483cdfca627af85040e7a21cf7eee911f81d99de9df5a173e222664a80b1382c58bec496f2e6b7022db8
@@ -4,8 +4,8 @@ add 'build', {
4
4
  'build_type' => 'chef',
5
5
 
6
6
  "base_image" => {
7
- "name" => "my-base-phusion-1604",
8
- "repository" => "my-base-phusion-1604",
7
+ "name" => "base-phusion-1604",
8
+ "repository" => "base-phusion-1604",
9
9
  "tag" => "latest"
10
10
 
11
11
  },
@@ -1,5 +1,15 @@
1
1
  # will be added to Docker image
2
2
 
3
+ #
4
+ ['/code'].each do |d|
5
+ directory d do
6
+ recursive true
7
+ action :create
8
+ end
9
+
10
+ end
11
+
12
+
3
13
  #
4
14
  =begin
5
15
  ['/var/www/html', 'var/www/temp'].each do |d|
@@ -353,6 +353,11 @@ class Manager
353
353
  # cache for server
354
354
  cmd("rm -rf #{settings.dir_server_root}/.chef/local-mode-cache")
355
355
  #cmd("rm -rf ~/.chef/package-cache")
356
+
357
+ # cache in gem
358
+ cmd("rm -rf #{Config.dir_gem_root}/lib/docker_builder/.chef/local-mode-cache")
359
+
360
+
356
361
  end
357
362
 
358
363
  ###
@@ -1,3 +1,3 @@
1
1
  module DockerBuilder
2
- VERSION = "0.1.16"
2
+ VERSION = "0.1.17"
3
3
  end
data/readme.md CHANGED
@@ -12,9 +12,37 @@ Other tools:
12
12
  * docker-composer - with configs in yml
13
13
 
14
14
 
15
+ Docker-builder is similar to docker-compose but has some more functionality to customize installation of servers on the host.
16
+
15
17
 
16
18
  # Overview
17
19
 
20
+ Process of installing server in Docker container consists of the following stages:
21
+
22
+ Process of building and running container on the host machine:
23
+ * Build Docker image
24
+ * it will create a Docker image on the host machine
25
+ * build using Dockerfile or Chef provisioning
26
+
27
+ * Run Docker container
28
+ * provision host machine - run scripts locally on the host machine. It can be shell script of Chef recipe
29
+ * run container - `docker run`
30
+ * provision container - run script inside the container. It can be shell script of Chef recipe
31
+
32
+ * Install systemd service on the host machine to run Docker container automatically (optional)
33
+
34
+ * Start/Stop container
35
+
36
+ * Destroy container
37
+
38
+ * Destroy image
39
+
40
+
41
+ Concepts of running Docker containers:
42
+ * you can rerun containers without losing data. Data is stored on the host machine and shared with container.
43
+
44
+
45
+
18
46
 
19
47
  Build Docker image:
20
48
  * from Dockerfile
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: docker-builder
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.16
4
+ version: 0.1.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max Ivak
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-12-07 00:00:00.000000000 Z
11
+ date: 2016-12-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler