-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Fork process into background #43
Comments
There isn't currently any built-in way. If you're going to put robut in upstart, don't you want it to run in the foreground anyway? It's my understanding that most modern process management (upstart, runit, etc.) prefers your apps run in the foreground instead of daemonizing. We currently run robut through runit, and it seems to work pretty well. |
You wouldn't expand on how you're doing it, would you? To be honest, we're having less disconnection issues now, either from our VPS being much more stable or HipChat's servers being more stable. But I'd still love to automate it further. |
Nothing too fancy. How experienced are you with runit? For the most part, we just have an |
Honestly, I'm not the best with it. I'm still thinking of the irc days when On Monday, September 29, 2014, Justin Weiss notifications@github.com
Richard |
Ah, OK. Yeah, if you’re using a decent process manager, you should just have it run it in the foreground. I just saw a good article about this: https://www.mikeperham.com/2014/09/22/dont-daemonize-your-daemons/ https://www.mikeperham.com/2014/09/22/dont-daemonize-your-daemons/ And this is a (kind of detailed) intro to runit: https://rubyists.github.io/2011/05/02/runit-for-ruby-and-everything-else.html https://rubyists.github.io/2011/05/02/runit-for-ruby-and-everything-else.html I can help answer specific questions, but I’m not good enough to write a complete guide to runit or anything :-)
|
(old issue) but we've found success dockerizing our Robut bot and publishing to a Kubernetes cluster. Our Dockerfile looks like this
|
Awesome! These days, I’d do the exact same thing.
… On Mar 20, 2017, at 3:10 PM, James Martin ***@***.***> wrote:
(old issue) but we've found success dockerizing our Robut bot and publishing to a Kubernetes cluster. Our Dockerfile looks like this
# Suppress apt-get warnings
ENV DEBIAN_FRONTEND noninteractive
ENV TERM linux
# Install VIM. Because you know. Editing a file is useful as shit.
RUN apt-get update && apt-get install -y --no-install-recommends vim
# Set working directory
ENV APP_HOME /app
WORKDIR /app
# Copy app to container
COPY . ./
RUN bundle install
# Default this image to start as "Site"
CMD ["robut", "Chatfile"]```
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#43 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AAAD_Gpa-Bkv-JgAWWa94CakkisRy1Mpks5rnvlBgaJpZM4CCiV0>.
|
Perhaps there's already a way to do this and I'm completely missing it, but I'd like to request a way to fork the process into the background. My goal is to put the bot in upstart or equivalent. Server hiccups cause him to disconnect, and seeing the process die would be helpful.
The text was updated successfully, but these errors were encountered: