Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

thinking-sphinx-monit

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

thinking-sphinx-monit

  • 1.0.1
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

ThinkingSphinxMonit

Monit integration with Thinking Sphinx and CapistranoV3

Installation

Add this line to your application's Gemfile:

gem 'thinking-sphinx-monit'

And then execute:

$ bundle install

Usage

Add to your capfile following line:

# Capfile
require 'thinking_sphinx_monit/capistrano'

Before any other action please first deploy your app to server (needed for all stages which you want to use):

cap <stage> deploy

Then you can specify thinking sphinx hooks in your deploy.rb, for example like this:

before 'deploy:updating', 'thinking_sphinx:stop'
after 'deploy:published', 'thinking_sphinx:start'
after 'thinking_sphinx:start', 'thinking_sphinx:index'

That's because monit is started and stopped before and after thinking_sphinx stop/start:

before 'thinking_sphinx:stop', 'thinking_sphinx_monit:unmonitor'
after 'thinking_sphinx:start', 'thinking_sphinx_monit:monitor'

Of course you can do everything manually:

cap thinking_sphinx_monit:config     # Generates Thinking Sphinx monit-service
cap thinking_sphinx_monit:monitor    # Monitor Thinking Sphinx monit-service
cap thinking_sphinx_monit:restart    # Restart Thinking Sphinx monit-service
cap thinking_sphinx_monit:start      # Start Thinking Sphinx monit-service
cap thinking_sphinx_monit:stop       # Stop Thinking Sphinx monit-service
cap thinking_sphinx_monit:unmonitor  # Unmonitor Thinking Sphinx monit-service

Defaults

set :thinking_sphinx_monit_conf_dir, -> { "/etc/monit/conf.d/#{ts_monit_service_name}.conf" }
set :thinking_sphinx_use_sudo, true
set :thinking_sphinx_monit_bin, '/usr/bin/monit'

Dependencies

  • 'capistrano', '~> 3.0', '>= 3.0.0'
  • 'thinking-sphinx', '~> 3.3.0'

Customizing Monit template

If you need change config for Monit, you can:

bundle exec rails generate thinking_sphinx_monit:template

and edit template in your config/deploy/templates folder.

Contributing

Feel free to contribute.

FAQs

Package last updated on 08 Feb 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc