Skip to main content

AWS F# Lambda Web Server

This example lives in the pulumi/examples repository. Check out just this directory to use it:

Get started with this example
git clone --filter=blob:none --sparse https://github.com/pulumi/examples pulumi-examples
git -C pulumi-examples sparse-checkout set aws-fs-lambda-webserver
cd pulumi-examples/aws-fs-lambda-webserver

This example creates a web server in AWS lambda using the Giraffe web server

Deploying the App#

To deploy your infrastructure, follow the below steps.

Prerequisites#

  1. Install Pulumi
  2. Configure AWS Credentials

Steps#

After cloning this repo, from this working directory, run these commands:

  1. Build and publish the lambda function, making the output available to our Pulumi program.
Terminal window
dotnet publish ./LambdaWebServer
  1. Execute our Pulumi program to archive our published function output, and create our lambda.
Terminal window
pulumi up -C ./pulumi
  1. In a browser, navigate to the URL for websiteUrl. You should see the welcome message.

Related

The infrastructure as code platform for any cloud.