Comments (4)
I was able to get it working with God by using this for the config. Still testing it out to see if it'll work in all cases, but so far so good:
puma_pid = "#{rails_root}/tmp/pids/puma.pid"
puma_state = "#{rails_root}/tmp/pids/puma.state"
God.watch do |w|
w.dir = "#{rails_root}"
w.name = "puma"
w.env = {"RAILS_ENV"=>rails_env}
w.pid_file = "#{puma_pid}"
w.start = "bundle exec puma -C #{rails_root}/config/puma.rb"
w.stop = "bundle exec pumactl -S #{puma_state} stop"
w.restart = "bundle exec pumactl -S #{puma_state} restart"
end
I also had to comment out require 'capistrano/puma' in the Capfile because I use god to restart the processes in deploy.rb:
namespace :deploy do
desc 'Restart application'
task :restart do
on roles(:app), in: :sequence, wait: 5 do
within(current_path) do
# Reload god and restart its processes
execute :bundle, "exec god load config/app.god"
execute :bundle, "exec god restart puma"
end
end
end
from capistrano-puma.
There is a alpha support for monit if you want to keep your application up.
by adding : require 'capistrano/puma/monit' to the Capfile
I didn't know about that god gem. I will look into it and report back.
from capistrano-puma.
God is basically a 'monit like' written in ruby. If you want to write the tasks, i will merge them.
from capistrano-puma.
this gem don't restart puma automatically , so it should not interfere with your setting.
IMO you should not trust a ruby daemon watch over processes.
from capistrano-puma.
Related Issues (20)
- Puma 6.x HOT 4
- Permission denied with puma_access.log HOT 11
- Couple of issues with 6.0.beta HOT 2
- puma:restart service not found during deploy HOT 4
- Multiple X-Forwarded-Proto headers causing issues HOT 1
- WatchdogSec causes error when using Type=simple HOT 2
- Deploying a new app to a staging server won't start/restart puma/systemd HOT 3
- support for Puma v6.0 and upwards HOT 1
- release 5.x with support for Puma v6.0 HOT 1
- v6.0.0.beta.1 breaks Nginx functionality HOT 5
- Failed with result 'watchdog'. HOT 2
- capistrano doesn't support puma:stop task HOT 1
- When 6.0 GA? HOT 1
- after gem updates deploy fails with can't find service HOT 1
- Release 6.0.0 HOT 4
- Capistrano Puma Not Starting HOT 4
- WatchdogSec should be configurable
- Should this be considered abandoned? HOT 4
- Update to Puma 6 with capistrano3-puma 6.0.0.beta.1 HOT 1
- Installation hooks for initial start? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from capistrano-puma.