Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Minio source Kamelet #25

Merged
merged 2 commits into from
Feb 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/modules/ROOT/assets/images/kamelets/minio-source.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/modules/ROOT/nav.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* xref:ROOT:bitcoin-source.adoc[image:kamelets/bitcoin-source.svg[] Bitcoin Source]
* xref:ROOT:http-source.adoc[image:kamelets/http-source.svg[] HTTP Source]
* xref:ROOT:jira-source.adoc[image:kamelets/jira-source.svg[] Jira Source]
* xref:ROOT:minio-source.adoc[image:kamelets/minio-source.svg[] Minio Source]
* xref:ROOT:mqtt-source.adoc[image:kamelets/mqtt-source.svg[] MQTT Source]
* xref:ROOT:salesforce-source.adoc[image:kamelets/salesforce-source.svg[] Salesforce Source]
* xref:ROOT:slack-source.adoc[image:kamelets/slack-source.svg[] Slack Source]
Expand Down
64 changes: 64 additions & 0 deletions docs/modules/ROOT/pages/minio-source.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT
= image:kamelets/minio-source.svg[] Minio Source

*Provided by: "Apache Software Foundation"*

Receive data from Minio.

== Configuration Options

The following table summarizes the configuration options available for the `minio-source` Kamelet:
[width="100%",cols="2,^2,3,^2,^2,^3",options="header"]
|===
| Property| Name| Description| Type| Default| Example
| *accessKey {empty}* *| Access Key| The access key obtained from Minio| string| |
| *secretKey {empty}* *| Secret Key| The secret key obtained from Minio| string| |
| bucketNameOrArn| Bucket Name| The Minio Bucket name| string| |
| deleteAfterRead| Auto-delete objects| Delete objects after consuming them| boolean| `true`|
|===

NOTE: Fields marked with ({empty}*) are mandatory.

== Usage

This section summarizes how the `minio-source` can be used in various contexts.

=== Knative Source

The `minio-source` Kamelet can be used as Knative source by binding it to a Knative object.

.minio-source-binding.yaml
[source,yaml]
----
apiVersion: camel.apache.org/v1alpha1
kind: KameletBinding
metadata:
name: minio-source-binding
spec:
source:
ref:
kind: Kamelet
apiVersion: camel.apache.org/v1alpha1
name: minio-source
properties:
accessKey: "The Access Key"
secretKey: "The Secret Key"
sink:
ref:
kind: InMemoryChannel
apiVersion: messaging.knative.dev/v1
name: mychannel

----

Make sure you have xref:latest@camel-k::installation/installation.adoc[Camel K installed] into the Kubernetes cluster you're connected to.

Save the `minio-source-binding.yaml` file into your hard drive, then configure it according to your needs.

You can run the source using the following command:

[source,shell]
----
kubectl apply -f minio-source-binding.yaml
----
// THIS FILE IS AUTOMATICALLY GENERATED: DO NOT EDIT
58 changes: 58 additions & 0 deletions minio-source.kamelet.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
apiVersion: camel.apache.org/v1alpha1
kind: Kamelet
metadata:
name: minio-source
annotations:
camel.apache.org/kamelet.icon: "data:image/svg+xml;base64,PHN2ZyBkYXRhLW5hbWU9IkxheWVyIDEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDE2Mi42MTIgMjQuNDY1Ij48cGF0aCBkPSJNNTIuNzUxLjQxNGg5LjEwOHYyMy42M2gtOS4xMDh6TTQxLjcxMS43NGwtMTguNDg4IDkuOTJhLjkxOS45MTkgMCAwIDEtLjg1NiAwTDMuODc5Ljc0QTIuODA4IDIuODA4IDAgMCAwIDIuNTU4LjQxNGgtLjAyM0EyLjQgMi40IDAgMCAwIDAgMi42NDF2MjEuMzc2aDkuMVYxMy44NDJhLjkxOC45MTggMCAwIDEgMS4zODUtLjY4MmwxMC4zNjEgNS41NjhhMy42MzQgMy42MzQgMCAwIDAgMy4zMzYuMDI4bDEwLjkzMy01LjYzNGEuOTE3LjkxNyAwIDAgMSAxLjM3MS42OXYxMC4yMDVoOS4xVjIuNjQxQTIuNCAyLjQgMCAwIDAgNDMuMDU1LjQxNGgtLjAyM2EyLjgwOCAyLjgwOCAwIDAgMC0xLjMyMS4zMjZ6bTY1LjU2NC0uMzI2aC05LjIzN3YxMC43NTVhLjkxMy45MTMgMCAwIDEtMS4zMzguNzA2TDcyLjc2Mi42NzVhMi44MjQgMi44MjQgMCAwIDAtMS4xOTEtLjI2MWgtLjAxNmEyLjQgMi40IDAgMCAwLTIuNTM1IDIuMjI3djIxLjM3N2g5LjE2M1YxMy4yNzVhLjkxNC45MTQgMCAwIDEgMS4zMzctLjcwN2wyNC4wMzIgMTEuMmEyLjgxMyAyLjgxMyAwIDAgMCAxLjE4OC4yNiAyLjQgMi40IDAgMCAwIDIuNTM1LTIuMjI3em03LjE2MSAyMy42M1YuNDE0aDQuMTkxdjIzLjYzem0yOC44NTYuNDIxYy0xMS4yNzQgMC0xOS4yNzItNC43LTE5LjI3Mi0xMi4yMzJDMTI0LjAyIDQuNzQxIDEzMi4wNjYgMCAxNDMuMjkyIDBzMTkuMzIgNC43IDE5LjMyIDEyLjIzMy03LjkwMiAxMi4yMzItMTkuMzIgMTIuMjMyem0wLTIxLjMzM2MtOC4zODMgMC0xNC44NCAzLjIxNy0xNC44NCA5LjEgMCA1LjkyNiA2LjQ1NyA5LjEgMTQuODQgOS4xczE0Ljg4Ny0zLjE3NCAxNC44ODctOS4xYzAtNS44ODMtNi41MDQtOS4xLTE0Ljg4Ny05LjF6IiBmaWxsPSIjYzcyYzQ4Ii8+PC9zdmc+"
camel.apache.org/provider: "Apache Software Foundation"
labels:
camel.apache.org/kamelet.type: "source"
spec:
definition:
title: "Minio Source"
description: |-
Receive data from Minio.
required:
- bucketName
- accessKey
- secretKey
properties:
bucketNameOrArn:
title: Bucket Name
description: The Minio Bucket name
type: string
deleteAfterRead:
title: Auto-delete objects
description: Delete objects after consuming them
type: boolean
x-descriptors:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: true
accessKey:
title: Access Key
description: The access key obtained from Minio
type: string
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:password
secretKey:
title: Secret Key
description: The secret key obtained from Minio
type: string
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:password
types:
out:
mediaType: application/json
dependencies:
- "camel:jackson"
flow:
from:
uri: "minio:{{bucketName}}"
parameters:
secretKey: "{{secretKey}}"
accessKey: "{{accessKey}}"
deleteAfterRead: "{{deleteAfterRead}}"
steps:
- marshal:
json: {}
- to: "kamelet:sink"