
Security News
Researcher Exposes Zero-Day Clickjacking Vulnerabilities in Major Password Managers
Hacker Demonstrates How Easy It Is To Steal Data From Popular Password Managers
Easily integrate a Rack application into AWS Lambda.
Provides adapters to convert AWS Lambda events to Rack environment requests and Rack responses to AWS Lambda proxy integrations.
Shelf currently works with API Gateway.
Add to your Gemfile:
gem 'rack-shelf'
or gemspec:
spec.add_dependency 'rack-shelf'
In your AWS Lambda handler file:
require 'rack/shelf'
class App
def call
[200, {}, ['Hello world!']]
end
end
def handler(event:, context:)
Rack::Shelf.api_gateway(App.new, event, context)
end
The #api_gateway
method indicates the Lambda is expected to be invoked by API Gateway.
The method accepts three arguments: the Rack application, the Lambda event, and the Lambda context.
Shelf will translate the Lambda information to a Rack environment instance and invoke #call
on the application.
It then takes the return value of #call
(the three-element array) and translates it to a hash.
That hash contains the expected keys and values for an AWS Lambda proxy integration.
FAQs
Unknown package
We found that rack-shelf 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
Hacker Demonstrates How Easy It Is To Steal Data From Popular Password Managers
Security News
Oxlint’s new preview brings type-aware linting powered by typescript-go, combining advanced TypeScript rules with native-speed performance.
Security News
A new site reviews software projects to reveal if they’re truly FOSS, making complex licensing and distribution models easy to understand.