GithubHelp home page GithubHelp logo

chef-puma's People

Contributors

adamcrown avatar bai avatar chrismacnaughton avatar dependabot[bot] avatar giorgenes avatar lpmi-13 avatar timfjord avatar tpitale avatar wtfiwtz avatar yourabi avatar

Stargazers

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

Watchers

 avatar  avatar

chef-puma's Issues

puma_pid not set

I set up a very simple puma deploy, I only set repo_url and puma_role. When I tried to deploy, it failed trying to stop puma:

DEBUG[da937ddc] Running /usr/bin/env [ -f  ] on 10.0.0.2
DEBUG[da937ddc] Command: [ -f  ]
DEBUG[da937ddc] Finished in 0.003 seconds with exit status 0 (successful).
DEBUG[40ba6f3f] Running /usr/bin/env kill -0 $( cat  ) on 10.0.0.2
DEBUG[40ba6f3f] Command: kill -0 $( cat  )

It seems like the defaults task is being run?

`logrotate false` param ignored

I noticed this today while using chef-puma. With the following configuration, I'm observing chef-puma creating logrotate config files in /etc/logrotate.d regardless of the inclusion of logrotate false.

%w{example-one-com example-two-com}.each do |name|
  root_path    = "/var/www/#{name}"
  current_path = "#{root_path}/current"
  shared_path  = "#{root_path}/shared"

  puma_config name do
    owner 'www-data'
    group 'www-data'

    directory      current_path
    working_dir    current_path
    rackup         "#{current_path}/config.ru"

    puma_directory shared_path
    config_path    "#{shared_path}/puma.config"

    pidfile    "#{shared_path}/pids/puma.pid"
    state_path "#{shared_path}/pids/puma.state"

    bind             "unix://#{shared_path}/pids/puma.sock"
    control_app_bind "unix://#{shared_path}/pids/pumactl.sock"

    logrotate false
    monit false
    upstart true
  end
end

I did some digging in and found this issue on logrotate where a user reports that logrotate ignores the only_if evaluation because logrotate_app is implemented as a definition instead of an LWRP. chef-puma attempts to use only_if on line 163 in definitions/puma_config.rb.

I put together a fix for the issue here but didn't open a pull request as I was seeing some errors (specifically with foodcritic) when running the test suite with rake.

I'm not terribly familiar with cookbook development so figured I'd open this issue and get your thoughts.

Thanks!

monit clean shutdown

monit stop will cleanly shutdown Puma however when the system is shutdown Puma can be left in an inconsistent state (sock fd mostly and stale pid file).

Investigate the best way of packaging this with the Cookbook

Idea: one alternative might be to check if PID in pidfile is present, if not call puma_kill.sh first and then start normally.

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.