Skip to main content

Setting up Hanlon Development Environment (Update)

This is an update to my previous post Setting up Hanlon Development Environment. This update reflects the latest script changes incorporated


Operating System: Support any standard Linux distribution (Ubuntu LTS 14.04)
Database: MongoDB
Web Server: Trinidad
Dev Tools: JRuby development enviroment with necessary gems
Others: git, make, openjdk7, etc.,

Setting up

Update your linux to get all the latest distributions

apt-get install updates

1. Install pre-requisites

apt-get install -y git make mongodb openjdk-7-jre-headless g++ curl


2. Install ruby environment with your preferred Ruby environment manager like rvm or rbenv (I prefer using rvm) and setup jruby as your default environment

\curl -sSL | bash -s stable --ruby=jruby
source /usr/local/rvm/scripts/rvm
rvm use jruby –default


3. Setup Hanlon working directory (My preferred location ~/wspace/hanlon) and clone hanon git repository

mkdir wspace
git clone hanlon


4. Install / update ruby gems

cd hanlon
bundle install
gem install bundler trinidad

Hanlon now comes with scripted support both for trinidad and puma. (I prefer running trinidad)


5. Run hanlon initialization script


This script creates config file and necessary directory structure to run hanlon.


6. Edit hanlon client and server configuration files

Now hanlon client and server configuration files are segregated to reflect right configuration parameter. Files created by hanlon_init (samples included below) are suitable for most of the practical purpose. Do edit them (just in case) before starting the server


# This file is the main configuration for ProjectHanlon
# -- this was system generated --
--- !ruby/object:ProjectHanlon::Config::Client
noun: config
admin_port: 8025
api_port: 8026
api_version: v1
base_path: /hanlon/api
hanlon_log_level: Logger::ERROR
http_timeout: 60


# This file is the main configuration for ProjectHanlon
# -- this was system generated --
--- !ruby/object:ProjectHanlon::Config::Server
noun: config
admin_port: 8025
api_port: 8026
api_version: v1
base_path: /hanlon/api
daemon_min_cycle_time: 30
force_mk_uuid: ''
hanlon_log_level: Logger::ERROR
hnl_mk_boot_debug_level: Logger::ERROR
hnl_mk_boot_kernel_args: ''
image_path: /home/user/wspace/hanlon/image
ipmi_password: ''
ipmi_username: ''
ipmi_utility: ''
mk_checkin_interval: 60
mk_checkin_skew: 5
mk_gemlist_uri: /gems/gem.list
mk_kmod_install_list_uri: /kmod-install-list
mk_log_level: Logger::ERROR
mk_tce_install_list_uri: /tce-install-list
node_expire_timeout: 300
persist_dbname: project_hanlon
persist_mode: :mongo
persist_password: ''
persist_port: 27017
persist_timeout: 10
persist_username: ''
register_timeout: 120
sui_allow_access: 'true'
sui_mount_path: /docs


7. Run trinidad server

cd web


Popular posts from this blog

Distinguished Engineer Award

Congrats! CSC Distinguished Engineers & Architects 2017

Yesterday CSC announced Distinguished Engineers & Architects, Batch 2017
Congrats to all the distinguished folks. Welcome on board...
Distinguished Architects  Randy Arthur (Americas) serves as product owner for CSC’s IaaS offerings and as a lead solutions architect for complex integration projects involving cloud computing technologies. During his 16-year career with CSC, Randy  has worked successfully in various roles including midrange service delivery, pre-sales solution development and product management. He was the first CTO of CSC’s Cloud  technology “incubator.” Bio on | LinkedIn| Twitter
Graham Chastney(UKI&N) is a global domain architect experienced in workplace technologies,  solution strategy and solution governance. He is a global collaborator who is relied upon to provide thought leadership to solution teams and to build and development teams. Graham is the founder  and lead author of the Technology Perspectives blog, which he regards as part of a broader ambition to …