Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
This is an automatic reloading version of the rackup command that's shipped with Rack. It can be used as an alternative to the complex reloading logic provided by web frameworks or in environments that don't support application reloading.
The shotgun command starts one of Rack's supported servers (e.g., mongrel, thin, webrick) and listens for requests but does not load any part of the actual application. Each time a request is received, it forks, loads the application in the child process, processes the request, and exits the child process. The result is clean, application-wide reloading of all source files and templates on each request.
Installation:
gem install shotgun
Starting a server with a rackup file:
shotgun config.ru
Using Thin and starting on port 6000 instead of 9393 (default):
shotgun --server=thin --port=6000 config.ru
Running Sinatra apps:
shotgun hello.rb
See 'shotgun --help' for more advanced usage.
Because of the underlying technique used, Shotgun is only compatible with
systems that support fork(2)
(probably just MRI on POSIX systems).
For performance reasons, Shotgun automatically includes middleware to serve
static files (similar to Rack::Static
). If you rely on Rack serving static
assets, then do include Rack::Static
yourself.
If you use Sinatra, you may need to set the session secret manually.
Similar to a Rackup file (config.ru
), you can't use require_relative
in
your preload files (shotgun.rb
).
The reloading system in Ian Bicking's webware framework served as inspiration for the approach taken in Shotgun. Ian lays down the pros and cons of this approach in the following article:
FAQs
Unknown package
We found that shotgun demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.