Azure Functions Swift support

Hey @Helge_Hess1I'm using Files & Stencil for codegen, to generate files & directories required by Azure Functions. Currently part of the codegen needs to be done in the worker itself. It's on my todo to move the codegen to the CLI tool along with using SPMDestinations, it will definitely save time & steps!

I'm actually interested in contributing to such a builder to deploy to both Azure & AWS, since both support HTTP traffic for requests! It think it will be very nice for the community :smiley:

Ah cool, that seems fine. Maybe it would make sense to decouple such infrastructure code from the actual runtime (SwiftAzureRuntime and SwiftAzureFunctions packages)? Though you already seem to have a azure-functions-swift-tools :thinking:?

BTW: I'd love to get the SPMDestination stuff rewritten in Swift (it's all bash right now). Might not be too hard with Shell etc.

The thing I didn't find very nice is that I had to install all the .NET stuff to get started. But I suppose there is no way around that?

2 Likes

I'm using Files & Stencil for codegen

Soto for AWS uses Stencil for code generation.

1 Like

Yes azure-functions-swift-tools is the CLI tool package (to create project, functions, run locally, etc..).
There are a couple of ways to decouple infra code from the actual runtime, I'm thinking to explore moving as much as possible to the CLI tool.

Oh .NET installation is Not required! That was addressed a long time ago. Azure Functions have BundleExtensions that custom runtimes can use to bypass the .NET Core SDK installation and this worker utilizes them! Since the main post is not editable now, here is the updated getting started guide Azure Functions in Swift: From Code to Azure - DEV Community.
A lot has changed since the initial release!

One of goals of this framework is to make it as simple and as straightforward as possible for Swift devs to write Azure Functions without needing to think so much about the Azure Functions runtime (apart from the triggers, bindings and hosting of course)

2 Likes