From 36297176e4803129f87470910bf35d92d013f2fa Mon Sep 17 00:00:00 2001 From: swaggboi Date: Sun, 20 Feb 2022 03:07:15 -0500 Subject: [PATCH] Set threads dynamically --- Dockerfile | 2 +- config/puma.rb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 config/puma.rb diff --git a/Dockerfile b/Dockerfile index ba4be1c..5ed81fd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,4 +17,4 @@ RUN bundle install EXPOSE 4567 # Send it -CMD ["bundle", "exec", "puma", "-p", "4567", "-t", "2", "-e", "production"] +CMD ["bundle", "exec", "puma", "-p", "4567", "-e", "production"] diff --git a/config/puma.rb b/config/puma.rb new file mode 100644 index 0000000..9d18384 --- /dev/null +++ b/config/puma.rb @@ -0,0 +1 @@ +threads(1, `nproc`.chomp || 5)