Closed zw963 closed 3 years ago
This is expected. If you don't provide a value for :root
, the default value that is used when a root directory is needed is the current working directory of the process. However, Roda does not explicitly set the :root
option (or any other options).
the default value that is used when a root directory is needed is the current working directory of the process.
Don't understand clear, sorry, so, if we want get this default value in a roda app, how to do that?
Dir.pwd
returns the current working directory of the process.
Hi, i saw following document in
mastering roda
.:root sets the root path to the application in the file system. It is used for setting default paths for various parts of the application.
It defaults to the current working directory of the process
, so if our Roda application is being run from a different directory, we should definitely set this.But, i test it with
rackup
,puma
, orProcofile
, allopts[:root]
return nil.in fact, i can't see any key name match
root
, following is my optsPlease check my repo source code here for reproduce:
https://github.com/zw963/marketbet_crawler
Roda: 3.4.6 Ruby 3.0.2 puma 5.3.2
Thank you.