You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2021/12/22 14:16:01 UTC

[camel-kamelets] branch tag-github-source created (now 466b600)

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a change to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git.


      at 466b600  Added Github Tag Source Kamelet - Templates

This branch includes the following new commits:

     new 7bf48fb  Added Github Tag Source Kamelet
     new 9b16137  Added Github Tag Source Kamelet
     new 61b51a5  Added Github Tag Source Kamelet
     new ab0985e  Added Github Tag Source Kamelet - Docs
     new 466b600  Added Github Tag Source Kamelet - Templates

The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


[camel-kamelets] 04/05: Added Github Tag Source Kamelet - Docs

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit ab0985ec5bf8651dd8bb1a077cb698346a3f22bb
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Wed Dec 22 15:15:16 2021 +0100

    Added Github Tag Source Kamelet - Docs
---
 .../assets/images/kamelets/github-tag-source.svg   |   3 +
 docs/modules/ROOT/pages/github-tag-source.adoc     | 153 +++++++++++++++++++++
 2 files changed, 156 insertions(+)

diff --git a/docs/modules/ROOT/assets/images/kamelets/github-tag-source.svg b/docs/modules/ROOT/assets/images/kamelets/github-tag-source.svg
new file mode 100644
index 0000000..a8d1174
--- /dev/null
+++ b/docs/modules/ROOT/assets/images/kamelets/github-tag-source.svg
@@ -0,0 +1,3 @@
+<svg width="1024" height="1024" viewBox="0 0 1024 1024" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path fill-rule="evenodd" clip-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8C0 11.54 2.29 14.53 5.47 15.59C5.87 15.66 6.02 15.42 6.02 15.21C6.02 15.02 6.01 14.39 6.01 13.72C4 14.09 3.48 13.23 3.32 12.78C3.23 12.55 2.84 11.84 2.5 11.65C2.22 11.5 1.82 11.13 2.49 11.12C3.12 11.11 3.57 11.7 3.72 11.94C4.44 13.15 5.59 12.81 6.05 12.6C6.12 12.08 6.33 11.73 6.56 11.53C4.78 11.33 2.92 10.64 2.92 7.58C2.92 6.71 3.23 5.99 3.74 5.43C3.66 5.23 3.38 4.41 3.82 3.31C3.82 3.31 4.49 3.1 6.02 4.13C6.66 3.95 7. [...]
+</svg>
diff --git a/docs/modules/ROOT/pages/github-tag-source.adoc b/docs/modules/ROOT/pages/github-tag-source.adoc
new file mode 100644
index 0000000..ef0c6fb
--- /dev/null
+++ b/docs/modules/ROOT/pages/github-tag-source.adoc
@@ -0,0 +1,153 @@
+// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT
+
+= image:kamelets/github-tag-source.svg[] Github Tag Source
+
+*Provided by: "Apache Software Foundation"*
+
+*Support Level for this Kamelet is: "Preview"*
+
+Receive Tags From a Github Repository.
+
+== Configuration Options
+
+The following table summarizes the configuration options available for the `github-tag-source` Kamelet:
+[width="100%",cols="2,^2,3,^2,^2,^3",options="header"]
+|===
+| Property| Name| Description| Type| Default| Example
+| *oauthToken {empty}* *| OAuth Token| Oauth token| string| | 
+| *repoName {empty}* *| Repository Name| The Github Repository name| string| | 
+| *repoOwner {empty}* *| Repository Owner| The repository owner| string| | 
+|===
+
+NOTE: Fields marked with an asterisk ({empty}*) are mandatory.
+
+
+== Dependencies
+
+At runtime, the `github-tag-source` Kamelet relies upon the presence of the following dependencies:
+
+- camel:jackson
+- camel:github
+- camel:kamelet 
+
+== Usage
+
+This section describes how you can use the `github-tag-source`.
+
+=== Knative Source
+
+You can use the `github-tag-source` Kamelet as a Knative source by binding it to a Knative object.
+
+.github-tag-source-binding.yaml
+[source,yaml]
+----
+apiVersion: camel.apache.org/v1alpha1
+kind: KameletBinding
+metadata:
+  name: github-tag-source-binding
+spec:
+  source:
+    ref:
+      kind: Kamelet
+      apiVersion: camel.apache.org/v1alpha1
+      name: github-tag-source
+    properties:
+      oauthToken: "The OAuth Token"
+      repoName: "The Repository Name"
+      repoOwner: "The Repository Owner"
+  sink:
+    ref:
+      kind: Channel
+      apiVersion: messaging.knative.dev/v1
+      name: mychannel
+  
+----
+
+==== *Prerequisite*
+
+You have xref:{camel-k-version}@camel-k::installation/installation.adoc[Camel K installed] on the cluster.
+
+==== *Procedure for using the cluster CLI*
+
+. Save the `github-tag-source-binding.yaml` file to your local drive, and then edit it as needed for your configuration.
+
+. Run the source by using the following command:
++
+[source,shell]
+----
+kubectl apply -f github-tag-source-binding.yaml
+----
+
+==== *Procedure for using the Kamel CLI*
+
+Configure and run the source by using the following command:
+
+[source,shell]
+----
+kamel bind github-tag-source -p "source.oauthToken=The OAuth Token" -p "source.repoName=The Repository Name" -p "source.repoOwner=The Repository Owner" channel:mychannel
+----
+
+This command creates the KameletBinding in the current namespace on the cluster.
+
+=== Kafka Source
+
+You can use the `github-tag-source` Kamelet as a Kafka source by binding it to a Kafka topic.
+
+.github-tag-source-binding.yaml
+[source,yaml]
+----
+apiVersion: camel.apache.org/v1alpha1
+kind: KameletBinding
+metadata:
+  name: github-tag-source-binding
+spec:
+  source:
+    ref:
+      kind: Kamelet
+      apiVersion: camel.apache.org/v1alpha1
+      name: github-tag-source
+    properties:
+      oauthToken: "The OAuth Token"
+      repoName: "The Repository Name"
+      repoOwner: "The Repository Owner"
+  sink:
+    ref:
+      kind: KafkaTopic
+      apiVersion: kafka.strimzi.io/v1beta1
+      name: my-topic
+  
+----
+
+==== *Prerequisites*
+
+* You've installed https://strimzi.io/[Strimzi].
+* You've created a topic named `my-topic` in the current namespace.
+* You have xref:{camel-k-version}@camel-k::installation/installation.adoc[Camel K installed] on the cluster.
+
+==== *Procedure for using the cluster CLI*
+
+. Save the `github-tag-source-binding.yaml` file to your local drive, and then edit it as needed for your configuration.
+
+. Run the source by using the following command:
++
+[source,shell]
+----
+kubectl apply -f github-tag-source-binding.yaml
+----
+
+==== *Procedure for using the Kamel CLI*
+
+Configure and run the source by using the following command:
+
+[source,shell]
+----
+kamel bind github-tag-source -p "source.oauthToken=The OAuth Token" -p "source.repoName=The Repository Name" -p "source.repoOwner=The Repository Owner" kafka.strimzi.io/v1beta1:KafkaTopic:my-topic
+----
+
+This command creates the KameletBinding in the current namespace on the cluster.
+
+== Kamelet source file
+
+https://github.com/apache/camel-kamelets/blob/main/kamelets/github-tag-source.kamelet.yaml
+
+// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT

[camel-kamelets] 02/05: Added Github Tag Source Kamelet

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 9b161374ce7bbce36f451948cf3b22d2df821de6
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Wed Dec 22 15:14:48 2021 +0100

    Added Github Tag Source Kamelet
---
 .../kamelets/github-tag-source.kamelet.yaml        | 73 ++++++++++++++++++++++
 1 file changed, 73 insertions(+)

diff --git a/library/camel-kamelets/src/main/resources/kamelets/github-tag-source.kamelet.yaml b/library/camel-kamelets/src/main/resources/kamelets/github-tag-source.kamelet.yaml
new file mode 100644
index 0000000..c29f24d
--- /dev/null
+++ b/library/camel-kamelets/src/main/resources/kamelets/github-tag-source.kamelet.yaml
@@ -0,0 +1,73 @@
+# ---------------------------------------------------------------------------
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ---------------------------------------------------------------------------
+apiVersion: camel.apache.org/v1alpha1
+kind: Kamelet
+metadata:
+  name: github-tag-source
+  annotations:
+    camel.apache.org/kamelet.support.level: "Preview"
+    camel.apache.org/catalog.version: "main-SNAPSHOT"
+    camel.apache.org/kamelet.icon: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAyNCIgaGVpZ2h0PSIxMDI0IiB2aWV3Qm94PSIwIDAgMTAyNCAxMDI0IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTggMEMzLjU4IDAgMCAzLjU4IDAgOEMwIDExLjU0IDIuMjkgMTQuNTMgNS40NyAxNS41OUM1Ljg3IDE1LjY2IDYuMDIgMTUuNDIgNi4wMiAxNS4yMUM2LjAyIDE1LjAyIDYuMDEgMTQuMzkgNi4wMSAxMy43MkM0IDE0LjA5IDMuNDggMTMuMjMgMy4zMiAxMi43OEMzLjIzIDEyLjU1IDIuODQgMTEuOD [...]
+    camel.apache.org/provider: "Apache Software Foundation"
+    camel.apache.org/kamelet.group: "GitHub"
+  labels:
+    camel.apache.org/kamelet.type: "source"
+spec:
+  definition:
+    title: "Github Tag Source"
+    description: |-
+      Receive Tags From a Github Repository.
+    required:
+      - repoName
+      - repoOwner
+      - oauthToken
+    type: object
+    properties:
+      repoName:
+        title: Repository Name
+        description: The Github Repository name
+        type: string
+      repoOwner:
+        title: Repository Owner
+        description: The repository owner
+        type: string
+      oauthToken:
+        title: OAuth Token
+        description: Oauth token
+        type: string
+        format: password
+        x-descriptors:
+        - urn:alm:descriptor:com.tectonic.ui:password
+        - urn:camel:group:credentials
+  types:
+    out:
+      mediaType: application/json
+  dependencies:
+  - "camel:jackson"
+  - "camel:github"
+  - "camel:kamelet"
+  flow:
+    from:
+      uri: "github://tag"
+      parameters:
+        repoName: "{{repoName}}"
+        repoOwner: "{{repoOwner}}"
+        oauthToken: "{{oauthToken}}"
+      steps:
+      - marshal:
+          json: {}
+      - to: "kamelet:sink"

[camel-kamelets] 01/05: Added Github Tag Source Kamelet

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 7bf48fbbcec22e103cbe5982fac737c5fedccc26
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Wed Dec 22 15:14:32 2021 +0100

    Added Github Tag Source Kamelet
---
 kamelets/github-tag-source.kamelet.yaml | 73 +++++++++++++++++++++++++++++++++
 1 file changed, 73 insertions(+)

diff --git a/kamelets/github-tag-source.kamelet.yaml b/kamelets/github-tag-source.kamelet.yaml
new file mode 100644
index 0000000..c29f24d
--- /dev/null
+++ b/kamelets/github-tag-source.kamelet.yaml
@@ -0,0 +1,73 @@
+# ---------------------------------------------------------------------------
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# ---------------------------------------------------------------------------
+apiVersion: camel.apache.org/v1alpha1
+kind: Kamelet
+metadata:
+  name: github-tag-source
+  annotations:
+    camel.apache.org/kamelet.support.level: "Preview"
+    camel.apache.org/catalog.version: "main-SNAPSHOT"
+    camel.apache.org/kamelet.icon: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAyNCIgaGVpZ2h0PSIxMDI0IiB2aWV3Qm94PSIwIDAgMTAyNCAxMDI0IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTggMEMzLjU4IDAgMCAzLjU4IDAgOEMwIDExLjU0IDIuMjkgMTQuNTMgNS40NyAxNS41OUM1Ljg3IDE1LjY2IDYuMDIgMTUuNDIgNi4wMiAxNS4yMUM2LjAyIDE1LjAyIDYuMDEgMTQuMzkgNi4wMSAxMy43MkM0IDE0LjA5IDMuNDggMTMuMjMgMy4zMiAxMi43OEMzLjIzIDEyLjU1IDIuODQgMTEuOD [...]
+    camel.apache.org/provider: "Apache Software Foundation"
+    camel.apache.org/kamelet.group: "GitHub"
+  labels:
+    camel.apache.org/kamelet.type: "source"
+spec:
+  definition:
+    title: "Github Tag Source"
+    description: |-
+      Receive Tags From a Github Repository.
+    required:
+      - repoName
+      - repoOwner
+      - oauthToken
+    type: object
+    properties:
+      repoName:
+        title: Repository Name
+        description: The Github Repository name
+        type: string
+      repoOwner:
+        title: Repository Owner
+        description: The repository owner
+        type: string
+      oauthToken:
+        title: OAuth Token
+        description: Oauth token
+        type: string
+        format: password
+        x-descriptors:
+        - urn:alm:descriptor:com.tectonic.ui:password
+        - urn:camel:group:credentials
+  types:
+    out:
+      mediaType: application/json
+  dependencies:
+  - "camel:jackson"
+  - "camel:github"
+  - "camel:kamelet"
+  flow:
+    from:
+      uri: "github://tag"
+      parameters:
+        repoName: "{{repoName}}"
+        repoOwner: "{{repoOwner}}"
+        oauthToken: "{{oauthToken}}"
+      steps:
+      - marshal:
+          json: {}
+      - to: "kamelet:sink"

[camel-kamelets] 05/05: Added Github Tag Source Kamelet - Templates

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 466b600fbd7a3f63b4dea5288b3e08ae8d4ebc18
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Wed Dec 22 15:15:24 2021 +0100

    Added Github Tag Source Kamelet - Templates
---
 .../bindings/camel-k/github-tag-source-binding.yaml  | 20 ++++++++++++++++++++
 .../bindings/core/github-tag-source-binding.yaml     | 11 +++++++++++
 2 files changed, 31 insertions(+)

diff --git a/templates/bindings/camel-k/github-tag-source-binding.yaml b/templates/bindings/camel-k/github-tag-source-binding.yaml
new file mode 100644
index 0000000..6536d79
--- /dev/null
+++ b/templates/bindings/camel-k/github-tag-source-binding.yaml
@@ -0,0 +1,20 @@
+apiVersion: camel.apache.org/v1alpha1
+kind: KameletBinding
+metadata:
+  name: github-tag-source-binding
+spec:
+  source:
+    ref:
+      kind: Kamelet
+      apiVersion: camel.apache.org/v1alpha1
+      name: github-tag-source
+    properties:
+      oauthToken: "The OAuth Token"
+      repoName: "The Repository Name"
+      repoOwner: "The Repository Owner"
+  sink:
+    ref:
+      kind: KafkaTopic
+      apiVersion: kafka.strimzi.io/v1beta1
+      name: my-topic
+  
\ No newline at end of file
diff --git a/templates/bindings/core/github-tag-source-binding.yaml b/templates/bindings/core/github-tag-source-binding.yaml
new file mode 100644
index 0000000..b6e32f8
--- /dev/null
+++ b/templates/bindings/core/github-tag-source-binding.yaml
@@ -0,0 +1,11 @@
+- route:
+    from:
+      uri: "kamelet:github-tag-source"
+      parameters:
+        oauthToken: "The OAuth Token"
+        repoName: "The Repository Name"
+        repoOwner: "The Repository Owner"
+    steps:
+      - to:
+          uri: "log:info"
+    
\ No newline at end of file

[camel-kamelets] 03/05: Added Github Tag Source Kamelet

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch tag-github-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 61b51a532eb2a3e76704b51a5a8dc8c3f10e7b15
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Wed Dec 22 15:15:08 2021 +0100

    Added Github Tag Source Kamelet
---
 docs/modules/ROOT/nav.adoc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc
index cc33cb3..94912f2 100644
--- a/docs/modules/ROOT/nav.adoc
+++ b/docs/modules/ROOT/nav.adoc
@@ -55,6 +55,7 @@
 * xref:ROOT:ftps-source.adoc[image:kamelets/ftps-source.svg[] FTPS Source]
 * xref:ROOT:github-commit-source.adoc[image:kamelets/github-commit-source.svg[] Github Commit Source]
 * xref:ROOT:github-source.adoc[image:kamelets/github-source.svg[] Github Source]
+* xref:ROOT:github-tag-source.adoc[image:kamelets/github-tag-source.svg[] Github Tag Source]
 * xref:ROOT:google-calendar-source.adoc[image:kamelets/google-calendar-source.svg[] Google Calendar Source]
 * xref:ROOT:google-functions-sink.adoc[image:kamelets/google-functions-sink.svg[] Google Functions Sink]
 * xref:ROOT:google-mail-source.adoc[image:kamelets/google-mail-source.svg[] Google Mail Source]