teuton 2.1.8 → 2.1.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (91) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -8
  3. data/bin/check_teuton +43 -0
  4. data/docs/changelog/contributions.md +32 -0
  5. data/docs/changelog/v2.1.md +22 -0
  6. data/docs/changelog/v2.2.md +29 -0
  7. data/docs/commands/README.md +105 -7
  8. data/docs/commands/example_check.md +54 -0
  9. data/docs/commands/example_run.md +112 -0
  10. data/docs/dsl/README.md +11 -9
  11. data/docs/dsl/definition/expect.md +25 -21
  12. data/docs/dsl/definition/group.md +5 -1
  13. data/docs/dsl/definition/result.md +45 -34
  14. data/docs/dsl/definition/run_local.md +34 -0
  15. data/docs/dsl/definition/run_remote.md +119 -0
  16. data/docs/dsl/definition/target.md +6 -0
  17. data/docs/dsl/execution/export.md +27 -19
  18. data/docs/dsl/execution/play.md +4 -0
  19. data/docs/dsl/execution/send.md +21 -2
  20. data/docs/dsl/execution/show.md +13 -8
  21. data/docs/dsl/setting/get.md +24 -8
  22. data/docs/dsl/setting/set.md +8 -3
  23. data/docs/install/README.md +19 -26
  24. data/docs/install/modes_of_use.md +27 -26
  25. data/docs/install/scripts.md +53 -36
  26. data/docs/install/vagrant_docker.md +56 -0
  27. data/docs/learn/README.md +13 -6
  28. data/docs/learn/example-01-target.md +78 -61
  29. data/docs/learn/example-02-config.md +152 -0
  30. data/docs/learn/example-03-remote-hosts.md +31 -25
  31. data/docs/learn/example-04-use.md +23 -17
  32. data/docs/learn/example-05-debug.md +24 -17
  33. data/docs/learn/example-06-log.md +70 -0
  34. data/lib/teuton/application.rb +7 -4
  35. data/lib/teuton/case_manager/case/case.rb +4 -1
  36. data/lib/teuton/case_manager/case/dsl/expect.rb +3 -1
  37. data/lib/teuton/case_manager/case/dsl/goto.rb +12 -7
  38. data/lib/teuton/case_manager/case/dsl/macro.rb +38 -0
  39. data/lib/teuton/case_manager/case/dsl/main.rb +1 -2
  40. data/lib/teuton/case_manager/case/dsl/target.rb +1 -1
  41. data/lib/teuton/case_manager/case/runner.rb +7 -7
  42. data/lib/teuton/case_manager/case_manager.rb +1 -20
  43. data/lib/teuton/case_manager/check_cases.rb +12 -2
  44. data/lib/teuton/case_manager/dsl.rb +4 -6
  45. data/lib/teuton/case_manager/export_manager.rb +29 -3
  46. data/lib/teuton/case_manager/report.rb +29 -8
  47. data/lib/teuton/case_manager/show.rb +8 -4
  48. data/lib/teuton/cli.rb +1 -0
  49. data/lib/teuton/cli/play.rb +1 -0
  50. data/lib/teuton/cli/version.rb +1 -4
  51. data/lib/teuton/files/config.yaml +0 -1
  52. data/lib/teuton/files/start.rb +1 -1
  53. data/lib/teuton/files/template/case.html +135 -0
  54. data/lib/teuton/files/template/resume.html +115 -0
  55. data/lib/teuton/project/laboratory/builtin.rb +2 -1
  56. data/lib/teuton/project/laboratory/dsl.rb +13 -15
  57. data/lib/teuton/project/laboratory/laboratory.rb +5 -1
  58. data/lib/teuton/project/laboratory/show.rb +21 -13
  59. data/lib/teuton/project/name_file_finder.rb +6 -1
  60. data/lib/teuton/project/project.rb +7 -3
  61. data/lib/teuton/project/readme/dsl.rb +3 -1
  62. data/lib/teuton/project/readme/readme.rb +37 -26
  63. data/lib/teuton/project/skeleton.rb +20 -4
  64. data/lib/teuton/report/close.rb +15 -11
  65. data/lib/teuton/report/formatter/formatter_factory.rb +10 -6
  66. data/lib/teuton/report/formatter/html_formatter.rb +16 -79
  67. data/lib/teuton/report/formatter/resume_html_formatter.rb +39 -0
  68. data/lib/teuton/report/formatter/resume_yaml_formatter.rb +7 -1
  69. data/lib/teuton/report/report.rb +5 -4
  70. data/lib/teuton/report/show.rb +55 -26
  71. metadata +26 -39
  72. data/docs/changelog/todo.md +0 -46
  73. data/docs/commands/create_skeleton.md +0 -31
  74. data/docs/commands/help.md +0 -13
  75. data/docs/commands/revise_test.md +0 -46
  76. data/docs/commands/run_test_unit.md +0 -78
  77. data/docs/commands/show_version.md +0 -9
  78. data/docs/developers/01-telnet.md +0 -121
  79. data/docs/developers/02-ssh.md +0 -93
  80. data/docs/developers/03-encoding.md +0 -153
  81. data/docs/developers/comparative.md +0 -17
  82. data/docs/dsl/_Sidebar.md +0 -30
  83. data/docs/dsl/definition/goto.md +0 -112
  84. data/docs/dsl/definition/run.md +0 -23
  85. data/docs/install/tested_os.md +0 -25
  86. data/docs/install/vagrant.md +0 -9
  87. data/docs/learn/example-02-configfile.md +0 -174
  88. data/docs/learn/quick-demo.md +0 -170
  89. data/lib/teuton/case_manager/case/dsl/check.rb +0 -24
  90. data/lib/teuton/case_manager/case/dsl/missing.rb +0 -12
  91. data/lib/teuton/files/gitignore +0 -2
@@ -1,3 +1,7 @@
1
+ [<< back](../../README.md)
2
+
3
+ 1. [Description](#description)
4
+ 2. [Usage](#usage)
1
5
 
2
6
  ## Description
3
7
 
@@ -1,3 +1,9 @@
1
+ [<< back](../../README.md)
2
+
3
+ 1. [Description](#description)
4
+ 2. [Usage](#usage)
5
+ 3. [Parameters](#parameters)
6
+ 4. [Send several reports](#send-several-reports)
1
7
 
2
8
  ## Description
3
9
 
@@ -16,7 +22,19 @@ end
16
22
  * `host1`, it' the label that identified remote host. This information must be configured into config file.
17
23
  * `send :copy_to => :host1`, copy every case resport file into temp directory on remote host `host1`.
18
24
 
19
- ## Other uses
25
+ ## Example
26
+
27
+ Example 1: send `case-01-txt` file to remote Windows host.
28
+
29
+ ![](images/send-remote-dir-dot1.jpg)
30
+
31
+ ![](images/send-remote-dir-dot2.jpg)
32
+
33
+ Example 2: send report file to remote "./Desktop" folder.
34
+
35
+ ![](images/send-remote-dir-desktop1.jpg)
36
+
37
+ ## Parameters
20
38
 
21
39
  | Action | Description |
22
40
  | ------ | ----------- |
@@ -27,11 +45,12 @@ end
27
45
  > * By default, `send` only works when remote OS type is UNIX base, like GNU/Linux, MACOS, BSD, etc.
28
46
  > * For Windows OS we must specified `:remote_dir`. Example: `send :copy_to => :host1, :remote_dir => "C:\\"`. This example will copy files on directory c:\ of host1 machine.
29
47
 
30
- ## How to send several output files
48
+ ## Send several reports
31
49
 
32
50
  If you export several files using differents output formats, you will use several `export` orders. Then when invoke `send` order, this will send the last exported file.
33
51
 
34
52
  In this example we export json and txt files, but only send txt to remote hosts:
53
+
35
54
  ```ruby
36
55
  start do
37
56
  export :format => :json
@@ -1,3 +1,8 @@
1
+ [<< back](../../README.md)
2
+
3
+ 1. [Description](#description)
4
+ 2. [Usage](#usage)
5
+ 3. [Parameters](#parameters)
1
6
 
2
7
  ## Description
3
8
 
@@ -7,15 +12,15 @@ When tests ends, `show` instruction shows on screen information about final resu
7
12
 
8
13
  ```ruby
9
14
  start do
10
- show
15
+ show
11
16
  end
12
17
  ```
13
18
 
14
- ## Other uses
19
+ ## Parameters
15
20
 
16
- | Action | Description |
17
- | --------------- | --------------------------------------- |
18
- | `show` | Same as `show :resume`. Default option. |
19
- | `show :resume` | Show resumed information on screen. |
20
- | `show :details` | Show details from every cases on screen.|
21
- | `show :all` | Same as `show :resume` and `show :details`. |
21
+ | Action | Description |
22
+ | -------------- | --------------------------------------- |
23
+ | `show` | Same as `show :resume`. Default option. |
24
+ | `show :resume` | Show resumed information on screen. |
25
+ | `show :cases` | Show information from every case on screen.|
26
+ | `show :all` | Same as `show :resume` and `show :details`. |
@@ -1,3 +1,8 @@
1
+ [<< back](../README.md)
2
+
3
+ 1. [Description](#description)
4
+ 2. [Usage](#usage)
5
+ 3. [Examples](#examples)
1
6
 
2
7
  ## Description
3
8
 
@@ -6,12 +11,13 @@
6
11
  ## Usage
7
12
 
8
13
  ```ruby
9
- get(:param1)
14
+ get(PARAM)
10
15
  ```
11
16
 
12
- ## Example
17
+ ## Examples
18
+
19
+ **Reading example**: Suppose we have this `config.yaml` content:
13
20
 
14
- Suppose we have this `config.yaml` content:
15
21
  ```yaml
16
22
  ---
17
23
  :global:
@@ -24,13 +30,23 @@ Suppose we have this `config.yaml` content:
24
30
  :username: obiwan
25
31
  ```
26
32
 
27
- Then:
33
+ Supossing we are **case 01**, then:
28
34
  * `get(:username)` returns `obiwan`.
29
35
  * `get(:host1_username)`, returns `root`.
30
36
 
31
- We also can create new temporal params:
37
+ **Writting example**: We also can create new temporal params:
38
+
32
39
  ```ruby
33
- set(:new_param, "Hello")
34
- var = get(:new_param)
40
+ set(:greet, "Hello")
41
+ var = get(:greet)
35
42
  ```
36
- So `var` value will be "Hello".
43
+
44
+ So `var` value is "Hello".
45
+
46
+ **Simpler reading example**: Other ways or reading param values:
47
+
48
+ ```ruby
49
+ var = greet?
50
+ ```
51
+
52
+ So `var` value is "Hello" too. `greet?` is an alias of `get(:greet)`.
@@ -1,3 +1,8 @@
1
+ [<< back](../README.md)
2
+
3
+ 1. [Description](#description)
4
+ 2. [Usage](#usage)
5
+ 3. [Example](#example)
1
6
 
2
7
  ## Description
3
8
 
@@ -12,7 +17,7 @@ set(:param1, 'value')
12
17
  ## Example
13
18
 
14
19
  ```ruby
15
- set(:new_param, "Hello")
16
- var = get(:new_param)
20
+ set(:greet, "Hello")
21
+ var = get(:greet)
17
22
  ```
18
- So `var` value will be "Hello".
23
+ So `var` value is "Hello".
@@ -1,56 +1,49 @@
1
1
  [<< back](../../README.md)
2
2
 
3
- # Teuton installation
3
+ # Installation
4
4
 
5
- There are different Teuton [Modes of use](modes_of_use.md). For every mode there are 2 node types and every node has their own installation:
5
+ > Definitions:
6
+ > * **T-node**: Host where Teuton software is installed. Monitor S-NODE hosts.
7
+ > * **S-node**: Host where SSH server is installed. This hosts are monitotized by T-NODE host.
8
+ >
9
+ > Read [Modes of use](modes_of_use.md) to know about different Teuton ways of using it.
6
10
 
7
- * **T-node**: This host has installed Teuton software.
8
- * **S-node**: This host has installed SSH server.
11
+ ## T-NODE installation
9
12
 
10
- ---
11
- # T-NODE
12
-
13
- * **Install** Teuton on machine with T-NODE role.
14
- Installation process:
13
+ * **Install** Teuton (T-NODE role host):
15
14
  1. Install Ruby on your system.
16
15
  2. `gem install teuton`
17
- * Run `teuton version` to check that your installation is ok.
16
+ * Run `teuton version` to check is fine.
18
17
 
19
- > **PROBLEMS**: If you have problems to find `teuton`command (OpenSUSE distro), try this:
18
+ > **PROBLEMS**: If you don't find `teuton`command (OpenSUSE distro), try this:
20
19
  > * Option A:
21
- > * `ruby -v`, display your current ruby version. Supose it is 2.5.
20
+ > * `ruby -v`, display your current ruby version. Suppose it is 2.5.
22
21
  > * Run `teuton.ruby2.5`, instead of `teuton`.
23
22
  > * Option B:
24
23
  > * `find /usr/lib64/ruby -name teuton`, to find absolute path to teuton command.
25
24
  > * `sudo ln -s /PATH/TO/bin/teuton /usr/local/bin/teuton`, to create symbolic link to teuton command.
26
25
 
27
- * **Update** Teuton with `gem teuton update`.
28
- * **Uninstall** Teuton with `gem uninstall teuton`
26
+ * **Update** with `gem teuton update`.
27
+ * **Uninstall** with `gem uninstall teuton`
29
28
 
30
- ---
31
- # S-NODE
29
+ ## S-NODE installation
32
30
 
33
31
  * **Install** SSH server on every machine with S-NODE role.
34
32
 
35
33
  ---
36
34
  # Other installation ways
37
35
 
38
- ## Using scripts
39
-
40
- [Installation using scripts](scripts.md)
36
+ **Scripts**. [Installation using scripts](scripts.md)
41
37
  * Use our scripts to run automatical installation for your OS.
42
38
  * Use this way if you don't know how to install Ruby on your system.
43
39
 
44
- ## Using Vagranfiles
40
+ **Vagrant or Docker**. [Installation using Vagrant or Docker](vagrant_docker.md)
41
+ * If you plan to install Teuton into virtual machines or containers.
45
42
 
46
- [Installation using Vagrant](vagrant.md)
47
- * If you plan to install Teuton into virtual machines, and have Vagrant installed into your real machine, this is the easier way for you.
48
-
49
- ## Manual
50
-
51
- [Manual installation](manual.md)
43
+ **Manual**. [Manual installation](manual.md)
52
44
  * If you don't need help, and want to install Teuton by your own, or there are not installation scripts for your favorite OS, and you don't want to use Vagrant then... here you have information how to install all the required packages for Teuton.
53
45
 
46
+ ---
54
47
  Let's us known your installation difficulties.
55
48
 
56
49
  Thanks!
@@ -1,38 +1,39 @@
1
- There are several **Teuton** ways of use: Classroom, Conquest and Standalone.
1
+ [<< back](README.md)
2
2
 
3
- For every mode exists 2 types of nodes: T-Node and S-Node.
3
+ # Modes of use
4
4
 
5
- ---
6
-
7
- ## Classroom mode
8
-
9
- In this mode, a teacher use **Teuton** tool to evaluate the work done by their students into their real or virtual machines. The teacher need to access remotely to these machines.
10
-
11
- | Node | Description |
12
- | ---- | ----------- |
13
- | T | Teacher install Teuton software into his machine, and he will connect remotely (using SSH) to every student machine. |
14
- | S | Every student machine. |
5
+ There are **Teuton** ways of use:
6
+ 1. Classroom
7
+ 2. Conquest and
8
+ 3. Standalone
15
9
 
16
10
  ---
11
+ ## 1. Classroom mode
17
12
 
18
- ## Contest mode
13
+ In this mode, teacher use **Teuton** tool to evaluate the work done by their students into their real or virtual machines. The teacher need to access remotely to these machines.
19
14
 
20
- We will hace a group of contestants who decide to do challenges and execute Teuton software into their own machines just to verify if satisfied the targets/goals of the challenge.
15
+ | Host | Description |
16
+ | ------ | ----------- |
17
+ | T-node | Teacher install Teuton software into his machine, and he will connect remotely (using SSH) to every student machine. |
18
+ | S-node | Every student machine. |
21
19
 
22
- On every run, Teuton software send results to remote server configured with SSH (used by the contest judges).
20
+ ## 2. Contest mode
23
21
 
24
- | Node | Description |
25
- | ---- | ------------------------------------------------------------ |
26
- | T | Every contest install Teuton software into their machine. Teuton wll connect via SSH to the server. |
27
- | S | The server used by judges to save all the reports. |
22
+ Group of contestants execute Teuton software into their own machines just to verify if satisfied the targets/goals of the contest challenge.
28
23
 
29
- ---
24
+ On every run, Teuton software send results to contest judges server.
25
+ Remote server is configured with SSH service.
26
+
27
+ | Host | Description |
28
+ | ------ | ------------------------------------------------------------ |
29
+ | T.node | Every contest install Teuton software into their machine. Teuton wll connect via SSH to the server. |
30
+ | S-node | The server used by judges to save all the reports. |
30
31
 
31
- ## Standalone mode
32
+ ## 3. Standalone mode
32
33
 
33
- Install Teuton software into our own machine, and execute the challenges as you want. It is a good way for standalone learning .
34
+ Student install Teuton software into his own machine, and execute the challenges standalone. It is a good way for practice and learn alone.
34
35
 
35
- | Node | Descripción |
36
- | ---- | ----------- |
37
- | T | Install Teuton software into our machine. |
38
- | S | No necessary. |
36
+ | Host | Descripción |
37
+ | ------ | ----------- |
38
+ | T-node | Install Teuton software into our machine. |
39
+ | S-node | No necessary. |
@@ -1,18 +1,23 @@
1
1
  [<< back](README.md)
2
2
 
3
- # Teuton installation using scripts
4
-
5
- There are different Teuton [Modes of use](modes_of_use.md). For every mode there are 2 node types and every node has their own installation script:
6
-
7
- * **T-node**: This host has installed Teuton software.
8
- * **S-node**: This host has installed SSH server.
9
-
10
- > Consult [tested OS](tested_os.md) to ensure if your favorite OS script installation has been tested.
3
+ # Using scripts to install Teuton
4
+
5
+ 1. T-Node installation
6
+ * GNU/Linux
7
+ * MACOSX
8
+ * Windows
9
+ 2. S-Node installation
10
+ * GNU/Linux
11
+ * MACOSX
12
+ * Windows
13
+ 3. Tested OS list
11
14
 
12
15
  ---
13
- # T-NODE installation
16
+ # 1. T-NODE installation
14
17
 
15
- ## T-NODE: GNU/Linux installation
18
+ * **T-node**: Host where Teuton software is installed. Monitor S-NODE hosts.
19
+
20
+ ## 1.1 T-NODE: GNU/Linux installation
16
21
 
17
22
  Run this command as `root` user:
18
23
 
@@ -20,17 +25,7 @@ Run this command as `root` user:
20
25
  wget -qO- https://raw.githubusercontent.com/teuton-software/teuton/devel/install/linux/linux_t-node_install.sh | bash
21
26
  ```
22
27
 
23
- ## T-NODE: Mac OS X installation
24
-
25
- Run this command as admin user (member of `admin` group):
26
-
27
- ```bash
28
- curl -sL https://raw.githubusercontent.com/teuton-software/teuton/devel/install/mac/macosx_t-node_install.sh | bash
29
- ```
30
-
31
- > No `root` user.
32
-
33
- ## T-NODE: Windows installation
28
+ ## 1.2 T-NODE: Windows installation
34
29
 
35
30
  Requirements:
36
31
  * Windows 7+ / Windows Server 2003+
@@ -39,34 +34,31 @@ Requirements:
39
34
  Run this command on **PowerShell (PS)** as `Administrator` user:
40
35
 
41
36
  ```powershell
42
- Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/teuton-software/teuton/devel/install/windows_t-node_install.ps1'))
37
+ Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/teuton-software/teuton/devel/install/windows/windows_t-node_install.ps1'))
43
38
  ```
44
39
 
45
- ---
46
-
47
- # S-NODE installation
40
+ ## 1.3 T-NODE: Mac OS X installation
48
41
 
49
- This is, SSH server installation.
50
-
51
- > The user from T-NODE have to know admin password/user to establish SSH connections to S-NODE.
52
-
53
- ## S-NODE: GNU/Linux installation
54
-
55
- Run this command as `root` user:
42
+ Run this command as admin user (member of `admin` group):
56
43
 
57
44
  ```bash
58
- wget -qO- https://raw.githubusercontent.com/teuton-software/teuton/devel/install/linux/linux_s-node_install.sh | bash
45
+ curl -sL https://raw.githubusercontent.com/teuton-software/teuton/devel/install/mac/macosx_t-node_install.sh | bash
59
46
  ```
60
47
 
61
- ## S-NODE: Mac OS X installation
48
+ ---
49
+ # 2. S-NODE installation
50
+
51
+ * **S-node**: Host where SSH server is installed. This hosts are monitotized by T-NODE host.
52
+
53
+ ## 2.1 S-NODE: GNU/Linux installation
62
54
 
63
55
  Run this command as `root` user:
64
56
 
65
57
  ```bash
66
- curl -sL https://raw.githubusercontent.com/teuton-software/teuton/devel/install/mac/macosx_s-node_install.sh | bash
58
+ wget -qO- https://raw.githubusercontent.com/teuton-software/teuton/devel/install/linux/linux_s-node_install.sh | bash
67
59
  ```
68
60
 
69
- ## S-NODE: Windows installation
61
+ ## 2.2 S-NODE: Windows installation
70
62
 
71
63
  Requirements:
72
64
  * Windows 7+ / Windows Server 2003+
@@ -77,3 +69,28 @@ Run this command on **PowerShell (PS)** as `Administrator` user:
77
69
  ```powershell
78
70
  Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/teuton-software/teuton/devel/install/windows/windows_s-node_install.ps1'))
79
71
  ```
72
+
73
+ ## 2.3 S-NODE: Mac OS X installation
74
+
75
+ Run this command as `root` user:
76
+
77
+ ```bash
78
+ curl -sL https://raw.githubusercontent.com/teuton-software/teuton/devel/install/mac/macosx_s-node_install.sh | bash
79
+ ```
80
+
81
+ ---
82
+ # 3. Tested OS list
83
+
84
+ | Type | O.S. | Version | Arch | T-node | S-node |
85
+ | --------- | --------- | -------------- | ------ | ------ | ------ |
86
+ | GNU/Linux | CentOS | 7 | x86-64 | | |
87
+ | | Debian | 9.7.0 | x86-64 | Ok | |
88
+ | | Fedora | Workstation 29 | x84-64 | Ok | |
89
+ | | LinuxMint | 18.3 | x86-64 | Ok | |
90
+ | | openSUSE | Leap 15 | x86-64 | Ok | Ok |
91
+ | | Ubuntu | 18.04 | x86-64 | Ok | Ok |
92
+ | Microsoft | Windows | 7 Enterprise | x86 | Ok | |
93
+ | | Windows | 10 Pro | x86-64 | Ok | Ok |
94
+ | | Windows | Server 2012 R2 | x86-64 | | |
95
+ | Apple | Mac OS X | Capitán (10.11.6) | x86-64 | Ok | Ok |
96
+ | | Mac OS X | Sierra (10.12) | x86-64 | Ok | |
@@ -0,0 +1,56 @@
1
+ [<< back](README.md)
2
+
3
+ # Vagrant and Docker installation
4
+
5
+ 1. Vagrant
6
+ 2. Docker
7
+
8
+ ---
9
+ # 1. Install using Vagrant
10
+
11
+ * First, install `Vagrant` and `VirtualBox` on your host.
12
+ * Create directory for vagrant project. For example, `mkdir teuton-vagrant`.
13
+ * Move into that directory: `cd teuton-vagrant`.
14
+ * Choose and download [Vagrantfile](../../install/vagrant).
15
+ * Run `vagrant up` to create your Virtual Machine.
16
+
17
+ # 2. Install using Docker
18
+
19
+ First:
20
+ * Install `docker` on your host.
21
+
22
+ Second, choose:
23
+ * Pulling docker image from remote or
24
+ * Rebuild local docker image.
25
+
26
+ ## 2.1 Pulling docker images from remote
27
+
28
+ Run this command to pull **dvarrui/teuton** image from Docker Hub and create teuton container:
29
+
30
+ `docker run --name teuton -v /home/teuton -i -t dvarrui/teuton /bin/bash`
31
+
32
+ ## 2.2 Rebuild local docker image
33
+
34
+ 1. Create Dockerfile like this:
35
+
36
+ ```
37
+ FROM debian:latest
38
+
39
+ MAINTAINER teuton 2.1
40
+
41
+ RUN apt-get update
42
+ RUN apt-get install -y apt-utils
43
+ RUN apt-get install -y vim tree
44
+ RUN apt-get install -y ruby
45
+ RUN gem install teuton
46
+ RUN mkdir /home/teuton
47
+
48
+ EXPOSE 80
49
+
50
+ WORKDIR /home/teuton
51
+ CMD ["/bin/bash"]
52
+ ```
53
+ 1. Build local docker image **dvarrui/teuton** with `docker build -t dvarrui/teuton .`
54
+ 1. Create **teuton** container with `docker run --name teuton -v /home/teuton -i -t dvarrui/teuton /bin/bash`.
55
+
56
+ > Notice `/home/teuton` folder is persistent volume.