How to tell if rails is in production?

后端 未结 6 1806
眼角桃花
眼角桃花 2020-12-23 11:20

I used script/server -e production to start rails in production mode. It did and I got no errors. However how do I tell if it is in production mode? I tried a n

6条回答
  •  不知归路
    2020-12-23 11:45

    I found it much easier to just restart the rails server and read the second line on the command line:

    Running rails s -e production outputs:

    => Booting Puma
    => Rails 4.2.4 application starting in `production` on http://localhost:3000
    

    Had Webrick in the example but some people didn't understand how changing servers would just substitute the name. Updated for clarity.

提交回复
热议问题