Configuring your toolchain
The AWS Toolkit for Visual Studio Code supports multiple languages across all the AWS services. The following sections describe how to configure your toolchain for different languages.
Configure a toolchain for .NET Core
-
Ensure that you have the AWS Toolkit for VS Code installed.
-
Install the C# extension
. This extension enables VS Code to debug .NET Core applications. -
Open an AWS Serverless Application Model (AWS SAM) application, or create one.
-
Open the folder that contains
template.yaml
.
Configure a toolchain for Node.js
-
Ensure that you have the AWS Toolkit for VS Code installed.
-
Open an AWS SAM application, or create one.
-
Open the folder that contains
template.yaml
.Note
When debugging a TypeScript Lambda function directly from the source code (launch configuration has
"target": "code"
), the TypeScript compiler must be installed either globally or in your project'spackage.json
.
Configure a toolchain for Python
-
Ensure that you have the AWS Toolkit for VS Code installed.
-
Install the Python extension for Visual Studio Code
. This extension enables VS Code to debug Python applications. -
Open an AWS SAM application, or create one.
-
Open the folder that contains
template.yaml
. -
Open a terminal at the root of your application, and configure
virtualenv
by runningpython -m venv ./.venv
.Note
You only need to configure
virtualenv
once per system. -
Activate
virtualenv
by running one of the following:-
Bash shell:
./.venv/Scripts/activate
-
PowerShell:
./.venv/Scripts/Activate.ps1
-
Configure a toolchain for Java
-
Ensure that you have the AWS Toolkit for VS Code installed.
-
Install the Java extension and Java 11
. This extension enables VS Code to recognize Java functions. -
Install the Java debugger extension
. This extension enables VS Code to debug Java applications. -
Open an AWS SAM application, or create one.
-
Open the folder that contains
template.yaml
.
Configure a toolchain for Go
-
Ensure that you have the AWS Toolkit for VS Code installed.
-
Go 1.14 or higher is required for debugging Go Lambda functions.
-
Install the Go extension
. Note
Version 0.25.0 or higher is required for debugging Go1.15+ runtimes.
-
Install Go tools using the command palette:
-
From the command palette, choose
Go: Install/Update Tools
. -
From the set of check boxes, select
dlv
andgopls
.
-
-
Open an AWS SAM application, or create one.
-
Open the folder that contains
template.yaml
.
Using Your toolchain
Once you have your toolchain set up, you can use it to run or debug the AWS SAM application.