dev-lxc 2.5.0 → 2.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8824c3d24a5ba9e63bca4fdeeec59220ea35f656
4
- data.tar.gz: b4f6c6304ceced41d0fc2913140d9540a55c6055
3
+ metadata.gz: ae5600852b4374df914684ee67a4d57471f4140f
4
+ data.tar.gz: cb8a2dfd12ef0330d3d52414b63704fd75b152a8
5
5
  SHA512:
6
- metadata.gz: a9618dd49101a04df2d44a01ecbc67439af667bb93fa9314c5012f8af8c228dccece53eac7608590cc76599e229d7d9fab7568697f5b3523f33412c40b3c1093
7
- data.tar.gz: 76897cac3f3b281060dc7ceb0fa667b71bfb74a127ea616bb1062f818c69a641062f0fd8aa95d8b646f2fe5499907286eb48f38b65c5e0134d7745ecd644fc85
6
+ metadata.gz: f408414657e710600d142565b9236c3f77037d0450fe564a77462fbec606289f9a48f2349afba3fb7698b14100b4454e485a32f3de32bade39cb51c73ab14ed4
7
+ data.tar.gz: 6fa526eb15c58413087b57d74809f62ac8832f92a6019964d94b79341a9fb3925bb45826dedbe7abeab9a91e8cf02b6bb2a74175672ccf57a93af4eca39cdcbe
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # dev-lxc Change Log
2
2
 
3
+ ## 2.6.0 (2017-02-09)
4
+
5
+ * Make api_fqdn unique for chef-tier and chef-backend configs
6
+ * Add https_proxy to generated knife.rb and client.rb files
7
+
3
8
  ## 2.5.0 (2017-02-08)
4
9
 
5
10
  * Add memory_per_server config option to limit memory per server
data/README.md CHANGED
@@ -123,10 +123,11 @@ mkdir -p /root/work/clusters/automate
123
123
 
124
124
  Then use the `init` subcommand to generate a sample configuration using the available options. Run `dl help init` to see what options are available.
125
125
 
126
- The following command configures a standalone Chef Server, a Chef Automate server and a job dispatch runner.
126
+ The following command configures a standalone Chef Server, Supermarket server, Compliance server,
127
+ Chef Automate server, and a job dispatch runner.
127
128
 
128
129
  ```
129
- dl init --chef --automate --runners -f /root/work/clusters/automate/dev-lxc.yml
130
+ dl init --chef --compliance --supermarket --automate --runners -f /root/work/clusters/automate/dev-lxc.yml
130
131
  ```
131
132
 
132
133
  We can easily append additional configurations to this file. For example, the following command appends an infrastructure node.
@@ -190,7 +191,7 @@ This can be helpful when you don't want to start building the cluster yet but yo
190
191
 
191
192
  At this point all of the cluster's servers should be running.
192
193
 
193
- If you setup the workstation's networking correctly as described in the prerequisites you should be able to ping any server from your workstation using it's FQDN. You can also browse to any server that has a web interface.
194
+ If you enabled dynamic forwarding (SOCKS v5) in your workstation's SSH config file and configured a web browser to use the SOCKS v5 proxy as described in the dev-lxc-platform README.md then you should be able to browse from your workstation to any dev-lxc server that has a web interface using its FQDN.
194
195
 
195
196
  Since the cluster has a Chef Server you can use the `chef-repo` subcommand to create a chef-repo directory in the host instance that contains a knife.rb and all of the keys for the users and org validator clients that are defined in dev-lxc.yml. This makes it very easy to use tools such as knife or berkshelf.
196
197
 
@@ -212,11 +213,19 @@ You can use the `attach` subcommand to login to the root user of a server.
212
213
  For example, the following command should attach to the Chef Server.
213
214
 
214
215
  ```
215
- dl at chef
216
+ dl attach chef
216
217
  ```
217
218
 
218
219
  Since the cluster has a Chef Server and an infrastructure node dev-lxc made sure it configured the node's chef-client for the Chef Server so it is easy to converge the node.
219
220
 
221
+ ### Use mitmproxy to view HTTP traffic
222
+
223
+ Run `mitmproxy` in a terminal on the host instance.
224
+
225
+ Uncomment the `https_proxy` line in the `chef-repo/.chef/knife.rb` or in a node's `/etc/chef/client.rb` so traffic will be proxied through mitmproxy.
226
+
227
+ Run chef-client in the node or knife commands from the chef-repo and watch the HTTP requests appear in the mitmproxy console.
228
+
220
229
  ### Manage the Cluster
221
230
 
222
231
  The right pane of the "cluster" window should show `dev-lxc status` output. This shows the status of each server including any existing snapshots.
@@ -4,11 +4,11 @@ dev-lxc uses a YAML configuration file named `dev-lxc.yml` to define a cluster.
4
4
 
5
5
  The `init` command generates sample config files for various server types.
6
6
 
7
- Let's generate a config for a cluster with a standalone Chef Server, Chef Automate server,
8
- private Supermarket server, job dispatch runner and an infrastructure node.
7
+ Let's generate a config for a cluster with a standalone Chef Server, Supermarket server,
8
+ Compliance server, Chef Automate server, job dispatch runner and an infrastructure node.
9
9
 
10
10
  ```
11
- dev-lxc init --chef --automate --supermarket --runners --nodes > dev-lxc.yml
11
+ dev-lxc init --chef --compliance --supermarket --automate --runners --nodes > dev-lxc.yml
12
12
  ```
13
13
 
14
14
  The contents of `dev-lxc.yml` should look like this.
@@ -57,6 +57,14 @@ chef-server:
57
57
  push-jobs-server:
58
58
  reporting:
59
59
 
60
+ compliance:
61
+ admin_user: admin # the password will be the same as the username
62
+ servers:
63
+ compliance.lxc:
64
+ ipaddress: 10.0.3.205
65
+ products:
66
+ compliance:
67
+
60
68
  supermarket:
61
69
  servers:
62
70
  supermarket.lxc:
@@ -94,12 +102,14 @@ nodes:
94
102
  The dev-lxc.yml config file is very customizable. You can add or remove mounts, products or servers,
95
103
  change ip addresses, server names, the base_container and more.
96
104
 
97
- As you can see there are four server types represented by five servers.
105
+ As you can see there are six server types represented by six servers.
98
106
 
99
107
  1. chef-server - chef.lxc
100
- 2. analytics - analytics.lxc
108
+ 2. compliance - compliance.lxc
101
109
  3. supermarket - supermarket.lxc
102
- 4. nodes - node-1.lxc
110
+ 4. automate - automate.lxc
111
+ 5. runners - runner-1.lxc
112
+ 6. nodes - node-1.lxc
103
113
 
104
114
  #### Global Settings
105
115
 
@@ -171,7 +181,7 @@ When defining a Chef Server you can include organizations and users that will be
171
181
  dev-lxc knows how to automatically configure Chef Server standalone, Chef Server tier topology,
172
182
  Chef Server HA 2.0 as well as Chef Automate, Chef Client, Analytics, Compliance and Supermarket.
173
183
 
174
- If a Chef Automate, Analytics server or Supermarket server is defined in the same config file as
184
+ If a Chef Automate server, Compliance server, Analytics server or Supermarket server is defined in the same config file as
175
185
  a Chef Server then each server will automatically be integrated with that Chef Server.
176
186
 
177
187
  If a node server with Chef Client or Chef DK installed is defined in the same config file as
data/lib/dev-lxc/cli.rb CHANGED
@@ -87,7 +87,7 @@ base_container: b-ubuntu-1404
87
87
  chef_tier_config = %Q(
88
88
  chef-server:
89
89
  topology: tier
90
- api_fqdn: chef.lxc
90
+ api_fqdn: chef-tier.lxc
91
91
  users: # a user's password will be the same as its username
92
92
  - mary-admin
93
93
  - joe-user
@@ -193,7 +193,7 @@ adhoc:
193
193
  )
194
194
  chef_backend_config = %Q(
195
195
  chef-backend:
196
- api_fqdn: chef.lxc
196
+ api_fqdn: chef-ha.lxc
197
197
  users: # a user's password will be the same as its username
198
198
  - mary-admin
199
199
  - joe-user
@@ -803,7 +803,9 @@ module DevLXC
803
803
  FileUtils.cp(validation_key, "#{server.container.config_item('lxc.rootfs')}/etc/chef/") if File.exists?(validation_key)
804
804
  end
805
805
 
806
- client_rb = %Q(chef_server_url '#{chef_server_url}'
806
+ client_rb = %Q(#https_proxy 'https://10.0.3.1:8080'
807
+
808
+ chef_server_url '#{chef_server_url}'
807
809
  validation_client_name '#{validation_client_name}'
808
810
  validation_key '/etc/chef/#{validation_client_name}.pem'
809
811
  ssl_verify_mode :verify_none
@@ -1027,7 +1029,8 @@ ssl_verify_mode :verify_none
1027
1029
  end
1028
1030
 
1029
1031
  def create_knife_config(fqdn, dot_chef_path)
1030
- knife_rb = %Q(
1032
+ knife_rb = %Q(#https_proxy 'https://10.0.3.1:8080'
1033
+
1031
1034
  username = "CHANGEME"
1032
1035
  orgname = "CHANGEME"
1033
1036
 
@@ -1,3 +1,3 @@
1
1
  module DevLXC
2
- VERSION = "2.5.0"
2
+ VERSION = "2.6.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dev-lxc
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.0
4
+ version: 2.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremiah Snapp
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-08 00:00:00.000000000 Z
11
+ date: 2017-02-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler