Important
Developers are highly recommended to use the OpenShift Toolkit extension for Knative Serverless Function
workflow to streamline their development process and ensure a seamless experience. All the latest features of Knative Serverless will be maintained in the OpenShift Toolkit extension, supported by Red Hat.
Knative is an Open-Source Enterprise-level solution to build Serverless and Event-Driven Applications. Thus running Serverless Containers in Kubernetes environments.
This extension for Knative provides the app developer with the tools and experience needed when working with Knative & Serverless Functions
on a Kubernetes cluster. Using this extension, developers can develop and deploy functions in a serverless way through guided IDE workflow.
-
Knative extension uses kn cli
1.13.0
and func cli1.13.0
. The extension will offer to download and install the dependencies if needed. -
YAML is validated using the VSCode-YAML extension
-
Users can log in to the Kubernetes cluster using VSCode Kubernetes extension.
NOTE: You will need to have the kubeconfig for the cluster that you are accessing stored locally.
This extension contributes two views (Knative and Functions) and the following settings:
function.explorer.create
: Create a new Knative Function in the current namespacefunction.explorer.refresh
: Refresh the Functions tree viewfunction.explorer.repository
: Manage installed template repositories. Once added, a template from the repository can be used when creating a new function.
- This view is used to showcase Active commands for a specified function. This includes Build, Deploy, and Run sessions. Once the command is executed for a given function, the node is displayed in the Sessions View. Users can also
Stop
the executing action. The logs can be seen in theOutput Channel
.
service.explorer.create
: Create a new Knative service in the current namespaceservice.explorer.openFile
: Display YAML for the selected itemservice.explorer.refresh
: Refresh the Explorer tree view
vscode-knative
supports several commands for interacting with Knative and Knative Functions; these are accessible via the tree context menu and via the command palette (Cmd+Shift+P
⌘⇧P on macOS or Ctrl+Shift+P
⌃⇧P on Windows and Linux)
Knative: Create Function
: Open up a wizard to create a new Function projectKnative: Build Function
: Build the function project as a container imageKnative: Run
: Runs the function locally in the current directory or in the directory specifiedKnative: Deploy Function
: Deploys a function to the currently configured Knative-enabled cluster.Knative: Undeploy
: Undeploys a function from the cluster.Knative: Add Config to Function
: Allows configuration of Volume mounts and environment variables for a function projectKnative: Remove Config from Function
: Remove Volume mounts, Environment variable from the function configurationKnative: Open in Browser
: Open the deployed function in your browserKnative: Refresh View
: Refresh the Function Tree View
Knative: Add Service
: Start a workflow to create a new ServiceKnative: Focus on Serving View
: Load and Open the Knative Serving viewKnative: Focus on Eventing View
: Load and Open the Knative Eventing viewKnative: Refresh View
: Refresh the Service/Eventing Tree ViewKnative: Add a Tag
: Add a new tag to a RevisionKnative: Delete
: Delete a service or a revision or an eventing resourceKnative: Open in Browser
: Open the service in your browser
- What is OpenShift Serverless
- Setting up OpenShift Serverless Functions - Red Hat Official Documentation
- Serverless Function CLI docs
- Knative Docs
See CHANGELOG for details.
This is an open-source project open to anyone. We are always looking for contributions from the Function Developer community.
For information on getting started, please take a look at the CONTRIBUTING instructions.
Download the most recent knative-<version>.vsix
file from the release and install it by following the instructions here. Stable releases are archived here.
If you find an issue, please file a bug and we will fix it as soon as possible.
- File a bug in GitHub Issues.
- Open a Discussion on GitHub.
The func Task Force meets @ 10:30 PST every Tuesday, we'd love to have you! For more information, see the invitation on the Knative Team Calendar.
MIT, See LICENSE for more information.
The Knative extension for Visual Studio Code collects anonymous usage data and sends it to Red Hat servers to help improve our products and services. Read our privacy statement to learn more. This extension respects the redhat.telemetry.enabled
setting which you can learn more about at https://github.com/redhat-developer/vscode-commons#how-to-disable-telemetry-reporting