I'm currently trying to pull in a Swift lambda into SLS, which I am currently able to get a local running server out of the box using Swift Lambda Runtime.
How do I extend Serverless Offline to proxy invocations for my swift function to this server so that it can respond to invocations?
I'm staring at these files and it does not seem extensible :)
Edit: I do see some effort in the codebase with the supportedProvided set of runtimes provided and provided.al2. I assume there might be some future consideration here? I can't see it being used elsewhere though. Updated my proposal below to align.
Proposed Solution
Option 1:
maybe a extension property in serverless.yml like the following
Feature Request
https://github.com/serverless/serverless/issues/11840
I'm currently trying to pull in a Swift lambda into SLS, which I am currently able to get a local running server out of the box using Swift Lambda Runtime.
How do I extend Serverless Offline to proxy invocations for my swift function to this server so that it can respond to invocations?
I'm staring at these files and it does not seem extensible :)
https://github.com/dherault/serverless-offline/blob/56d986b672602b3600fe9b552ecb4ee392ca2201/src/lambda/LambdaFunction.js
https://github.com/dherault/serverless-offline/blob/43dfea4fc97f57d439186523ab5e7b3bc3770e55/src/lambda/handler-runner/HandlerRunner.js
Edit: I do see some effort in the codebase with the
supportedProvided
set of runtimesprovided
andprovided.al2
. I assume there might be some future consideration here? I can't see it being used elsewhere though. Updated my proposal below to align.Proposed Solution
Option 1:
maybe a extension property in serverless.yml like the following
or maybe configuration in the
custom
propertyOption 2:
Or just simply a new Runner maintained by your team
Option 3:
or maybe a facility for adding custom runners for other plugins?
Option 4:
or expose some hooks?