GithubHelp home page GithubHelp logo

chef-boneyard / hubot Goto Github PK

View Code? Open in Web Editor NEW
40.0 6.0 48.0 109 KB

DEPRECATED: Chef cookbook for deploying and managing an instance of Github's Hubot.

Home Page: https://supermarket.chef.io/cookbooks/hubot

License: Apache License 2.0

HTML 10.40% Shell 4.08% Ruby 85.52%

hubot's Introduction

hubot cookbook

Build Status Cookbook Version

Deploys and manages an instance of GitHub's Hubot.

Requirements

Platforms

  • Debian/Ubuntu
  • RHEL/CentOS/Scientific/Amazon/Oracle

Chef

  • Chef 12.1+

Cookbooks

Recipes

default

  • Ensures that Node.js is installed and available using the
  • nodejs cookbook.
  • Ensures git is installed and available using the
  • git cookbook.
  • Ensures runit is installed and available using the
  • runit cookbook.
  • Creates a user and group to install and run the Hubot instance under.
  • Installs the specified Hubot version from git.
  • Renders instance-specific package.json, external-scripts.json, hubot-scripts.json, and
  • hubot.conf files.
  • Creates and enables a hubot runit service to run the Hubot instance under.
  • The runit service reads the hubot.conf file and passes the contents onto
  • the underlying hubot process as configuration.

Attributes

Attribute Description Type Default
version Hubot version to install. String 2.11.0
scripts_version Version of hubot-scripts (community collection of hubot scripts) to install. String 2.5.16
install_dir Directory the Hubot instance will be installed to. String /opt/hubot
user The user to install and run the Hubot instance under. String hubot
group The group to install and run the Hubot instance under. String hubot
name The name of the robot in chat. String hubot
adapter The Hubot adapter to use. String campfire
config Hash of values that will be converted into environment variables and passed to the Hubot process. Hash Hash.new
dependencies Hash in form dep_name => dep_version that will be rendered into Hubot instance's package.json. A common dep to set in this attribute is non-Campfire adapters. Hash Hash.new
hubot_scripts Scripts to enable from the community collection of hubot scripts. Array Array.new
external_scripts External scripts to enable. Array Array.new

Usage

Include recipe[hubot] in your run_list and override the defaults you want changed. See below for more details. Hubot instances are configured using environment variables passed to the Hubot process. These environment variables can be set using the node['hubot']['config'] attribute.

I highly recommend integrating this cookbook into your own infrastructure using the library/application cookbook pattern. You would start by creating a YOURCOMPANY-hubot cookbook with a proper metadata dependency on the hubot (this) cookbook. A concrete example can be found on this gist which was created from bits of the internal opscode-hubot cookbook which we use to deploy, Paula Deen, Chef's hubot instance.

One important item to note is the use of the remote_directory resource to distribute our internal hubot scripts to the install:

remote_directory "#{node['hubot']['install_dir']}/scripts" do
  source "scripts"
  files_backup 0
  files_owner node['hubot']['user']
  files_group node['hubot']['group']
  files_mode '0644'
  owner node['hubot']['user']
  group node['hubot']['group']
  overwrite true
  mode '0755'
  notifies :restart, "service[hubot]", :delayed
end

License & Authors

Author: [Seth Chisamore][schisamo] ([email protected])

Author: [Tim Smith][tas50] ([email protected])

Copyright: 2013-2015, Seth Chisamore

Copyright: 2015, Tim Smith Copyright: 2016, Chef Software, Inc

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

hubot's People

Contributors

8la avatar amaltson avatar barthv avatar docwhat avatar gad0lin avatar gitter-badger avatar gswallow avatar joekiller avatar psi avatar schisamo avatar streeter avatar tas50 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.