Complete the code to set the Puma server port to 3000.
port [1]The port directive sets the port number Puma listens on. Here, 3000 is the default port for Rails development.
Complete the code to specify the number of Puma worker processes as 2.
workers [1]The workers directive sets how many worker processes Puma will spawn. Setting it to 2 means Puma will run 2 separate processes to handle requests.
Fix the error in the code to correctly set the minimum number of threads to 1.
threads [1], 5
The threads directive takes two numbers: minimum and maximum threads. The minimum should be at least 1 to allow Puma to handle requests.
Complete the code to configure Puma to preload the application and bind to a Unix socket.
preload_app! bind '[1]'
preload_app! as a method.preload_app! tells Puma to load the app before workers fork, improving memory usage. Binding to a Unix socket is done with bind 'unix:///path'.
Fill all three blanks to configure Puma with 3 workers, thread count between 2 and 8, and a port of 4000.
workers [1] threads [2], [3] port 4000
This configuration sets Puma to use 3 worker processes, with threads ranging from 2 minimum to 8 maximum, and listens on port 4000.