diff --git a/README.md b/README.md index 59c5608e..561c9eca 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # OpenFunction Website -This project uses [Hugo](https://gohugo.io/) and [Hugo template Docsy](https://github.com/google/docsy) to build the OpenFunction website. +openfunction.dev is OpenFunction's website which is built with [Hugo](https://gohugo.io/) and [Hugo template Docsy](https://github.com/google/docsy). ## Contribute @@ -13,10 +13,10 @@ Contributions of any kind are welcome! 2. Run the following commands to clone your fork and enter into it. Make sure you replace `` with your GitHub ID. ``` - git clone https://github.com//website.git - cd website + git clone https://github.com//openfunction.dev.git + cd openfunction.dev ``` -### Build and preview the website +### Build and preview openfunction.dev #### Pre-requisites @@ -27,12 +27,12 @@ Contributions of any kind are welcome! 1. Ensure pre-requisites are installed 1. Clone repository -1. Change to website directory: `cd website` +1. Change to openfunction.dev directory: `cd openfunction.dev` 1. Add Docsy submodule: `git submodule add https://github.com/google/docsy.git themes/docsy` 1. Update submodules: `git submodule update --init --recursive` 1. Install npm packages: `npm install` -### Running the website locally +### Running openfunction.dev locally After you setup the environment, run the following command: @@ -40,11 +40,11 @@ After you setup the environment, run the following command: hugo server -D ``` -Now you can preview the website in your browser at `http://localhost:1313/`. +Now you can preview openfunction.dev in your browser at `http://localhost:1313/`. ### Open a pull request -Open a [pull request (PR)](https://help.github.com/en/desktop/contributing-to-projects/creating-an-issue-or-pull-request#creating-a-new-pull-request) to contribute to our website. Use DCO sign-off when you submit a PR by running the command below (add `-s`): +Open a [pull request (PR)](https://help.github.com/en/desktop/contributing-to-projects/creating-an-issue-or-pull-request#creating-a-new-pull-request) to contribute to openfunction.dev. Use DCO sign-off when you submit a PR by running the command below (add `-s`): ```bash git commit -s -m "xxx" diff --git a/config.toml b/config.toml index 55ae1f9e..48e3baaf 100644 --- a/config.toml +++ b/config.toml @@ -101,16 +101,19 @@ archived_version = false # The version number for the version of the docs represented in this doc set. # Used in the "version-banner" partial to display a version number for the # current doc set. -version = "0.0" +version = "0.6" # A link to latest version of the docs. Used in the "version-banner" partial to # point people to the main doc site. -url_latest_version = "/" +url_latest_version = "/docs" [[params.versions]] -version = "latest" -# url = "./docs" # If chinese document is avaliable -url = '/docs' + version = "v0.7 (latest)" + url = "https://openfunction.dev/docs/" + +[[params.versions]] + version = "v0.6" + url = "https://v0-6.openfunction.dev/docs/" # Repository configuration (URLs for in-page links to opening issues and suggesting changes) github_repo = "https://github.com/OpenFunction/website" @@ -120,7 +123,7 @@ github_repo = "https://github.com/OpenFunction/website" # Uncomment this if you have a newer GitHub repo with "main" as the default branch, # or specify a new value if you want to reference another branch in your GitHub links -github_branch= "main" +github_branch= "v0.6" # Google Custom Search Engine ID. Remove or comment out to disable search. # gcs_engine_id = "d72aa9b2712488cc3" diff --git a/content/en/docs/_index.md b/content/en/docs/_index.md index 14db929f..b08d2ae6 100644 --- a/content/en/docs/_index.md +++ b/content/en/docs/_index.md @@ -1,9 +1,9 @@ --- -title: "v0.6.0 (latest)" +title: "v0.6" linkTitle: "Docs" weight: 20 --- -Welcome to the OpenFunction documentation site! +Welcome to the OpenFunction documentation site! {{% alert title="What is OpenFunction?" color="success" %}} diff --git a/content/en/docs/concepts/Events/_index.md b/content/en/docs/concepts/Events/_index.md index 9ab96c1c..8e4d4839 100644 --- a/content/en/docs/concepts/Events/_index.md +++ b/content/en/docs/concepts/Events/_index.md @@ -1,6 +1,6 @@ --- -title: "Events" -linkTitle: "Events" +title: "OpenFunction Events" +linkTitle: "OpenFunction Events" weight: 4500 description: --- diff --git a/content/en/docs/concepts/Events/clustereventbus.md b/content/en/docs/concepts/Events/clustereventbus.md index b2475fb4..5aae309e 100644 --- a/content/en/docs/concepts/Events/clustereventbus.md +++ b/content/en/docs/concepts/Events/clustereventbus.md @@ -9,7 +9,7 @@ This document describes how to use a ClusterEventBus. ## Prerequisites -You have finished the steps described in [Use EventBus and Trigger](../use-event-bus-and-trigger). +You have finished the steps described in [Use EventBus and Trigger](../event-bus-and-trigger). ## Use a ClusterEventBus diff --git a/content/en/docs/concepts/Events/event-bus-and-trigger.md b/content/en/docs/concepts/Events/event-bus-and-trigger.md index bc480c4c..5d7c3ee6 100644 --- a/content/en/docs/concepts/Events/event-bus-and-trigger.md +++ b/content/en/docs/concepts/Events/event-bus-and-trigger.md @@ -9,8 +9,8 @@ This document gives an example of how to use EventBus and Trigger. ## Prerequisites -- You need to create a function as the target function to be triggered. For more information, see [Use EventSource](../use-event-source#create-a-function). -- You need to create a Kafka cluster. For more information, see [Use EventSource](../use-event-source#create-a-kafka-cluster). +- You need to create a function as the target function to be triggered. Please refer to [Create a function](../event-source#create-a-function) for more details. +- You need to create a Kafka cluster. Please refer to [Create a Kafka cluster](../event-source#create-a-kafka-cluster) for more details. ## Deploy an NATS streaming server diff --git a/content/en/docs/concepts/Events/event-source.md b/content/en/docs/concepts/Events/event-source.md index 19358dcb..19824c85 100644 --- a/content/en/docs/concepts/Events/event-source.md +++ b/content/en/docs/concepts/Events/event-source.md @@ -11,7 +11,7 @@ In this example, an EventSource is defined for synchronous invocation to use the ## Create a Function -Use the following content to create a function as the EventSource Sink. For more information about how to create a function, see [Your First Function: Go](../../../getting-started/your-first-function/function-go). +Use the following content to create a function as the EventSource Sink. For more information about how to create a function, see [Create sync functions](../../../getting-started/quickstarts/sync-functions). ```yaml apiVersion: core.openfunction.io/v1beta1 diff --git a/content/en/docs/concepts/Events/events.md b/content/en/docs/concepts/Events/introduction.md similarity index 87% rename from content/en/docs/concepts/Events/events.md rename to content/en/docs/concepts/Events/introduction.md index e6d7dfc1..1f1cbcec 100644 --- a/content/en/docs/concepts/Events/events.md +++ b/content/en/docs/concepts/Events/introduction.md @@ -1,15 +1,13 @@ --- -title: "Events" -linkTitle: "Events" +title: "Introduction" +linkTitle: "Introduction" weight: 3400 description: --- -This document describes the concept of Events in OpenFunction. - ## Overview -Events is the event management framework for OpenFunction. It provides the following core features: +OpenFunction Events is OpenFunction's event management framework. It provides the following core features: - Support for triggering target functions by synchronous and asynchronous calls - User-defined trigger judgment logic @@ -17,7 +15,7 @@ Events is the event management framework for OpenFunction. It provides the follo ## Architecture -The following diagram illustrates the architecture of Events. +The following diagram illustrates the architecture of OpenFunction Events. ![openfunction-events](/images/docs/en/concepts/events/openfunction-events.svg) diff --git a/content/en/docs/concepts/Events/multisource-in-eventsource.md b/content/en/docs/concepts/Events/multisource-in-eventsource.md index 982e0b25..373f47b0 100644 --- a/content/en/docs/concepts/Events/multisource-in-eventsource.md +++ b/content/en/docs/concepts/Events/multisource-in-eventsource.md @@ -9,8 +9,8 @@ This document describes how to use multiple sources in one EventSource. ## Prerequisites -- You need to create a function as the target function to be triggered. For more information, see [Use EventSource](../use-event-source#create-a-function). -- You need to create a Kafka cluster. For more information, see [Use EventSource](../use-event-source#create-a-kafka-cluster). +- You need to create a function as the target function to be triggered. Please refer to [Create a function](../event-source#create-a-function) for more details. +- You need to create a Kafka cluster. Please refer to [Create a Kafka cluster](../event-source#create-a-kafka-cluster) for more details. ## Use Multiple Sources in One EventSource diff --git a/content/en/docs/concepts/Events/trigger-conditions.md b/content/en/docs/concepts/Events/trigger-conditions.md index 1d0d8b0a..6010c499 100644 --- a/content/en/docs/concepts/Events/trigger-conditions.md +++ b/content/en/docs/concepts/Events/trigger-conditions.md @@ -9,7 +9,7 @@ This document describes how to use Trigger conditions. ## Prerequisites -You have finished the steps described in [Use EventBus and Trigger](../use-event-bus-and-trigger). +You have finished the steps described in [Use EventBus and Trigger](../event-bus-and-trigger). ## Use Trigger Conditions @@ -125,7 +125,7 @@ You have finished the steps described in [Use EventBus and Trigger](../use-event serving-4x5wh-ksvc-wxbf2-v100-deployment-5c495c84f6-k2jdg 2/2 Running 0 46s ``` -5. Create an event producer by referring to [Create an Event Producer](../../use-event-bus-and-trigger#create-an-event-producer). +5. Create an event producer by referring to [Create an Event Producer](../event-bus-and-trigger#create-an-event-producer). 6. Run the following command and you can see from the output that the `eventA && eventB` condition in the Trigger is matched and the event is sent to the `metrics` topic of the event bus at the same time. The OpenFuncAsync function is triggered. diff --git a/content/en/docs/concepts/function_build.md b/content/en/docs/concepts/function_build.md index 6767369f..b3dea376 100644 --- a/content/en/docs/concepts/function_build.md +++ b/content/en/docs/concepts/function_build.md @@ -29,7 +29,7 @@ spec: ## Customize functions framework version, valid for functions-framework-go for now ## Usually you needn't to do so because the builder will ship with the latest functions-framework # FUNC_FRAMEWORK_VERSION: "v0.3.0" - # Use FUNC_GOPROXY to set the goproxy + ## Use FUNC_GOPROXY to set the goproxy # FUNC_GOPROXY: "https://goproxy.cn" srcRepo: url: "https://github.com/OpenFunction/samples.git" diff --git a/content/en/docs/concepts/function_io.md b/content/en/docs/concepts/function_io.md index 8a4f93f1..2b85fec4 100644 --- a/content/en/docs/concepts/function_io.md +++ b/content/en/docs/concepts/function_io.md @@ -63,7 +63,7 @@ spec: value: "false" ``` -[Here](https://github.com/OpenFunction/samples/tree/main/functions/async/pubsub/subscriber) is another async function example that use a Kafka Pub/sub component as input. +[Here](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/pubsub/subscriber) is another async function example that use a Kafka Pub/sub component as input. ```yaml apiVersion: core.openfunction.io/v1beta1 @@ -94,7 +94,7 @@ spec: value: "autoscaling-subscriber" ``` -Sync functions can also send output to Dapr output binding components or Pub/sub components, [here](https://github.com/OpenFunction/samples/tree/main/functions/knative/with-output-binding) is an example: +Sync functions can also send output to Dapr output binding components or Pub/sub components, [here](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/with-output-binding) is an example: ```yaml apiVersion: core.openfunction.io/v1beta1 diff --git a/content/en/docs/concepts/function_signatures.md b/content/en/docs/concepts/function_signatures.md index 9e9733ec..d1d9298f 100644 --- a/content/en/docs/concepts/function_signatures.md +++ b/content/en/docs/concepts/function_signatures.md @@ -27,8 +27,8 @@ As you can see, `OpenFunction` signature is the recommended function signature, | | HTTP | CloudEvent | OpenFunction | |-----------|----------------|----------------------|------------------------| -| Go | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-go), [Multi-functions](https://github.com/OpenFunction/samples/tree/main/functions/knative/multiple-functions-go), [log processing](https://github.com/OpenFunction/samples/blob/main/functions/knative/logs-handler-function/LogsHandler.go) | | [Sync function with output binding](https://github.com/OpenFunction/samples/tree/main/functions/knative/with-output-binding), [Kafka input & HTTP output binding](https://github.com/OpenFunction/samples/tree/main/functions/async/logs-handler-function), [Cron input & Kafka output binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/cron-input-kafka-output), [Cron input binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/cron-input), [Kafka input binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/kafka-input), [Kafka pubsub](https://github.com/OpenFunction/samples/tree/main/functions/async/pubsub) | -| Nodejs | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-node) | | [Sync function with output binding](https://github.com/OpenFunction/samples/tree/main/functions/knative/with-output-binding-node), [MQTT binding & pubsub](https://github.com/OpenFunction/samples/tree/main/functions/async/mqtt-io-node) | -| Python | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-python) | | | -| Java | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-java) | | | -| DotNet | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-dotnet) | | | \ No newline at end of file +| Go | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-go), [log processing](https://github.com/OpenFunction/samples/blob/main/functions/knative/logs-handler-function/LogsHandler.go) | | [Sync function with output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/with-output-binding), [Kafka input & HTTP output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/logs-handler-function), [Cron input & Kafka output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/cron-input-kafka-output), [Cron input binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/cron-input), [Kafka input binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/kafka-input), [Kafka pubsub](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/pubsub) | +| Nodejs | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-node) | | | +| Python | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-python) | | | +| Java | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-java) | | | +| DotNet | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-dotnet) | | | \ No newline at end of file diff --git a/content/en/docs/getting-started/Quickstarts/async-functions.md b/content/en/docs/getting-started/Quickstarts/async-functions.md index 805364aa..5fbb428b 100644 --- a/content/en/docs/getting-started/Quickstarts/async-functions.md +++ b/content/en/docs/getting-started/Quickstarts/async-functions.md @@ -11,8 +11,8 @@ Async functions are event-driven and their inputs are usually events from Non-HT | | Async Functions | |-----------|-----------------| -| Go | [Kafka input & HTTP output binding](https://github.com/OpenFunction/samples/tree/main/functions/async/logs-handler-function), [Cron input & Kafka output binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/cron-input-kafka-output), [Cron input binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/cron-input), [Kafka input binding](https://github.com/OpenFunction/samples/tree/main/functions/async/bindings/kafka-input), [Kafka pubsub](https://github.com/OpenFunction/samples/tree/main/functions/async/pubsub) | -| Nodejs | [MQTT binding & pubsub](https://github.com/OpenFunction/samples/tree/main/functions/async/mqtt-io-node) | +| Go | [Kafka input & HTTP output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/logs-handler-function), [Cron input & Kafka output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/cron-input-kafka-output), [Cron input binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/cron-input), [Kafka input binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/bindings/kafka-input), [Kafka pubsub](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/pubsub) | +| Nodejs | [MQTT binding & pubsub](https://github.com/OpenFunction/samples/tree/release-0.6/functions/async/mqtt-io-node) | | Python | | | Java | | | DotNet | | diff --git a/content/en/docs/getting-started/Quickstarts/sync-functions.md b/content/en/docs/getting-started/Quickstarts/sync-functions.md index fef18c08..9a512e24 100644 --- a/content/en/docs/getting-started/Quickstarts/sync-functions.md +++ b/content/en/docs/getting-started/Quickstarts/sync-functions.md @@ -11,10 +11,10 @@ Sync functions are funtions whose inputs are payloads of HTTP requests, and the | | Sync Functions | |-----------|----------------| -| Go | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-go), [Multi-functions](https://github.com/OpenFunction/samples/tree/main/functions/knative/multiple-functions-go), [log processing](https://github.com/OpenFunction/samples/blob/main/functions/knative/logs-handler-function/LogsHandler.go), [Sync function with output binding](https://github.com/OpenFunction/samples/tree/main/functions/knative/with-output-binding) | -| Nodejs | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-node), [Sync function with output binding](https://github.com/OpenFunction/samples/tree/main/functions/knative/with-output-binding-node) | -| Python | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-python) | -| Java | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-java) | -| DotNet | [Hello World](https://github.com/OpenFunction/samples/tree/main/functions/knative/hello-world-dotnet) | +| Go | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-go), [Multi-functions](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/multiple-functions-go), [log processing](https://github.com/OpenFunction/samples/blob/main/functions/knative/logs-handler-function/LogsHandler.go), [Sync function with output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/with-output-binding) | +| Nodejs | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-node), [Sync function with output binding](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/with-output-binding-node) | +| Python | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-python) | +| Java | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-java) | +| DotNet | [Hello World](https://github.com/OpenFunction/samples/tree/release-0.6/functions/knative/hello-world-dotnet) | > You can find more function samples [here](../../../concepts/function_signatures/#samples) \ No newline at end of file diff --git a/content/en/docs/getting-started/installation.md b/content/en/docs/getting-started/installation.md index 87533599..be1d64ed 100644 --- a/content/en/docs/getting-started/installation.md +++ b/content/en/docs/getting-started/installation.md @@ -33,37 +33,59 @@ For more information about OpenFunction components compatibility with Kubernetes ## Install OpenFunction -### Option 1: Helm -This option is the **recommended** installation method. +### Option 1: Install with helm chart (recommended) #### Requirements - Kubernetes version: `>=v1.20.0-0` - Helm version: `>=v3.6.3` -#### install the chart -1. Run the following command to add the OpenFunction chart repository. +#### Steps to install OpenFunction helm charts + +1. Run the following command to add the OpenFunction chart repository first: ```shell helm repo add openfunction https://openfunction.github.io/charts/ helm repo update ``` -2. Run the following command to install the OpenFunction chart. - ```shell - kubectl create namespace openfunction - helm install openfunction openfunction/openfunction -n openfunction - ``` +2. Then you have several options to setup OpenFunction, you can choose to: + + - Install all components: + ```shell + kubectl create namespace openfunction + helm install openfunction openfunction/openfunction -n openfunction --version 0.1.0 + ``` + + - Install Serving only (without build): + ```shell + kubectl create namespace openfunction + helm install openfunction --set ShipwrightBuild.enabled=false --set TektonPipelines.enabled=false openfunction/openfunction -n openfunction --version 0.1.0 + ``` + + - Install Knative sync runtime only: + ```shell + kubectl create namespace openfunction + helm install openfunction --set Keda.enabled=false openfunction/openfunction -n openfunction --version 0.1.0 + ``` + + - Install OpenFunction async runtime only: + ```shell + kubectl create namespace openfunction + helm install openfunction --set IngressNginx.enabled=false --set KnativeServing.enabled=false openfunction/openfunction -n openfunction --version 0.1.0 + ``` + {{% alert title="Note" color="success" %}} For more information about how to install OpenFunction with Helm, see [Install OpenFunction with Helm](https://github.com/OpenFunction/charts/tree/release-0.6#install-the-chart). {{% /alert %}} -3. Run the following command to verify OpenFunction is ready. +3. Run the following command to verify OpenFunction is up and running: ```shell - kubectl get pods -namespace openfunction + kubectl get po -n openfunction ``` -### Option 2: CLI +### Option 2: Install with CLI + 1. Run the following command to download `ofn`, the CLI of OpenFunction. ```shell diff --git a/layouts/partials/navbar-lang-selector.html b/layouts/partials/navbar-lang-selector.html index 4080afc7..cf8317ae 100644 --- a/layouts/partials/navbar-lang-selector.html +++ b/layouts/partials/navbar-lang-selector.html @@ -1,6 +1,6 @@ {{/* Link directly to documentation etc., if possible. */}} {{ $langPage := cond (gt (len .Translations) 0) . .Site.Home }} -