Project

General

Profile

Actions

MS DHCP » History » Revision 2

« Previous | Revision 2/13 (diff) | Next »
Kai Stian Olstad, 09/13/2011 04:26 AM


MS DHCP

The Microsoft smart-proxy installation procedure is very basic compared to the RPM or APT based solution.

It is required that this procedure is executed as an administrator.

1) Go to the smart-proxy repository at https://github.com/ohadlevy/smart-proxy
2) Select download and choose the latest revision
3) Extract this to a directory that does not have any spaces in its name.
4) Go to the rubyinstaller webpage at http://rubyinstaller.org/downloads/
5) Download and install the latest ruby 1.8.7 release. (Allow the ruby associations to be installed.)
6) Download and install the latest DevKit release
6.1) ruby dk.rb init
6.2) ruby dk.rb install
7) Open a CMD window and, using gem install --version X.X.X --platform ?????, add these gems

columnize (0.3.2)
haml (3.0.24)
highline (1.6.1)
json (1.4.6 x86-mswin32)
linecache (0.43 mswin32)
mime-types (1.16)
mocha (0.9.11)
net-ping (1.3.7)
rack (1.2.0)
rake (0.8.7)
rest-client (1.6.1)
sinatra (1.1.0)
tilt (1.1)
win32-api (1.4.6 x86-mswin32-60)
win32-open3 (0.3.2 x86-mswin32-60)
win32-service (0.7.1 x86-mswin32-60)
windows-api (0.4.0)
windows-pr (1.1.2)

Command to download them all:

wget http://rubygems.org/downloads/columnize-0.3.2.gem \
     http://rubygems.org/downloads/haml-3.0.24.gem \
     http://rubygems.org/downloads/highline-1.6.1.gem \
     http://rubygems.org/downloads/json-1.4.6-x86-mswin32.gem \
     http://rubygems.org/downloads/linecache-0.43-mswin32.gem \
     http://rubygems.org/downloads/mime-types-1.16.gem \
     http://rubygems.org/downloads/mocha-0.9.11.gem \
     http://rubygems.org/downloads/net-ping-1.3.7.gem \
     http://rubygems.org/downloads/rack-1.2.0.gem \
     http://rubygems.org/downloads/rake-0.8.7.gem \
     http://rubygems.org/downloads/rest-client-1.6.1.gem \
     http://rubygems.org/downloads/sinatra-1.1.0.gem \
     http://rubygems.org/downloads/tilt-1.1.gem \
     http://rubygems.org/downloads/win32-api-1.4.6-x86-mswin32-60.gem \
     http://rubygems.org/downloads/win32-open3-0.3.2-x86-mswin32-60.gem \
     http://rubygems.org/downloads/win32-service-0.7.1-x86-mswin32-60.gem \
     http://rubygems.org/downloads/windows-api-0.4.0.gem \
     http://rubygems.org/downloads/windows-pr-1.1.2.gem

8) CD to the root of the smart-proxy install directory
9) Edit config/settings.yml so that it looks a bit like this

Sample config/settings.yml file

 ---
 # HTTPS settings
 :ssl_certificate: c:\documents\smart-proxy\config\signed.pem
 :ssl_private_key: c:\documents\smart-proxy\config\private.pem
 :ssl_ca_file:     c:\documents\smart-proxy\config\ca.pem

 :trusted_hosts: [ foreman.someware.com]

 :daemon: false

 # Enable DHCP management
 :dhcp: true
 # The vendor can be either isc or native_ms
 :dhcp_vendor: native_ms
 # The dhcp_server is only used by the native_ms implementation
 :dhcp_server: 172.29.90.240

 # Where our proxy log files are stored
 # filename or STDOUT
 # Unix setting
 #:log_file: log/proxy.log
 # Windows setting
 :log_file: c:\tmp\proxy.log
 # valid options are
 # Logger::WARN, Logger::DEBUG, Logger::Error, Logger::Fatal, Logger:INFO, LOGGER::UNKNOWN
 #:log_level: Logger::DEBUG

10) Create the SSL key
10.1) Login to your puppetmaster
10.2) puppetca --generate Smart-proxy FQDN. (Do not use an alias here.)
10.3) Copy the private key, the public certificate and the ca.pem from /var/lib/puppet/ssl over to the locations that you specified in the setting file.
11) Test the installation by running ruby bin\smart-proxy.rb
12) Install the program as a service
12.1) ruby extra\register-service.rb
12.2) This may install the service but not run it. If so then try to start the service from the Ordinary Microsoft services snapin utility.
13) You may test connectivity by running the extra\query.rb utility from your foreman host. (Note that this file comes from the extra directory in the smart-proxy release.)

Updated by Kai Stian Olstad over 12 years ago · 2 revisions