Skip to content

Example on how to use Camel K for a serverless integration with Minio

Notifications You must be signed in to change notification settings

GuilhermeCamposo/demo_serverless_minio

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Camel K Serveless Minio Integration Demo

Requirements

  • OpenShift Cluster

  • Camel K CLI - kamel

  • OpenShift CLI - oc

Preparing the Environment Using Ansible

Parameters

Parameter Example Value Definition

token

sha256~vFanQbthlPKfsaldJT3bdLXIyEkd7ypO_XPygY1DNtQ

access token for a user with cluster-admin privileges

server

https://api.${domain}.com:6443

Cluster API URL.

Running the playbook

You will need an user with permission to create a project and install operators on cluster level. Export the user’s token and the server API address as environment variables, then run the following command under the ansible folder:

cd ansible/

ansible-playbook -e token=${token} -e server=${server} playbook.yml

Running the Integration

Before using kamel CLI make sure your are connected to the right namespace.

oc login
oc project camel-k-serverless

Then move to camel-k folder and run the integration.

With properties:

kamel run --property file:minio.properties MinioUploader.java

With configmaps:

oc create -f minio-config.yml -n camel-k-serverless
kamel run --config configmap:minio-config MinioUploader.java

Testing the Integration

You may test your deployment using cURL:

ROUTE=$(oc get routes.serving.knative.dev minio-uploader  -o jsonpath='{.status.url}' -n camel-k-serverless)

curl --request POST $ROUTE --header 'Content-Type: text/plain' --data-raw 'This is the file content.'

About

Example on how to use Camel K for a serverless integration with Minio

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages