Skip to content

Commit

Permalink
fix(ci): validate kamelets directory
Browse files Browse the repository at this point in the history
Also changed the validator to warn if deprecated .kamelet.spec.flow is found

Closes #751
  • Loading branch information
squakez committed Jan 28, 2022
1 parent b871ef6 commit 64fd5fb
Show file tree
Hide file tree
Showing 27 changed files with 608 additions and 702 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/validate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,4 @@ jobs:
echo "Running Kamelet validator..."
cd script/validator
go run . ../../
go run . ../../kamelets/
1 change: 1 addition & 0 deletions kamelets/aws-cloudwatch-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ spec:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: false
dependencies:
- "camel:core"
- "camel:aws2-cw"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-ec2-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ spec:
type: string
example: eu-west-1
dependencies:
- "camel:core"
- "camel:aws2-ec2"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-kinesis-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ spec:
type: string
example: eu-west-1
dependencies:
- "camel:core"
- "camel:aws2-kinesis"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-s3-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ spec:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: false
dependencies:
- "camel:core"
- "camel:aws2-s3"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-secrets-manager-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ spec:
type: string
example: eu-west-1
dependencies:
- "camel:core"
- "camel:aws-secrets-manager"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-ses-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ spec:
type: string
example: eu-west-1
dependencies:
- "camel:core"
- "camel:aws2-ses"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/aws-sns-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ spec:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: false
dependencies:
- "camel:core"
- "camel:aws2-sns"
- "camel:kamelet"
flow:
Expand Down
15 changes: 8 additions & 7 deletions kamelets/azure-eventhubs-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,14 @@ spec:
- urn:alm:descriptor:com.tectonic.ui:password
- urn:camel:group:credentials
dependencies:
#TODO: these mvn:* dependencies must be removed after upgrading to camel 3.10
- "mvn:com.fasterxml.jackson.core:jackson-core:2.11.3"
- "mvn:com.fasterxml.jackson.core:jackson-annotations:2.11.3"
- "mvn:com.fasterxml.jackson.core:jackson-databind:2.11.3"
- "mvn:com.fasterxml.jackson.dataformat:jackson-dataformat-xml:2.11.3"
- "camel:azure-eventhubs"
- "camel:kamelet"
- "camel:core"
#TODO: these mvn:* dependencies must be removed after upgrading to camel 3.10
- "mvn:com.fasterxml.jackson.core:jackson-core:2.11.3"
- "mvn:com.fasterxml.jackson.core:jackson-annotations:2.11.3"
- "mvn:com.fasterxml.jackson.core:jackson-databind:2.11.3"
- "mvn:com.fasterxml.jackson.dataformat:jackson-dataformat-xml:2.11.3"
- "camel:azure-eventhubs"
- "camel:kamelet"
flow:
from:
uri: "kamelet:source"
Expand Down
5 changes: 3 additions & 2 deletions kamelets/azure-storage-blob-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ spec:
type: string
default: uploadBlockBlob
dependencies:
- "camel:azure-storage-blob"
- "camel:kamelet"
- "camel:core"
- "camel:azure-storage-blob"
- "camel:kamelet"
flow:
from:
uri: "kamelet:source"
Expand Down
1 change: 1 addition & 0 deletions kamelets/azure-storage-queue-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ spec:
- urn:alm:descriptor:com.tectonic.ui:password
- urn:camel:group:credentials
dependencies:
- "camel:core"
- "camel:azure-storage-queue"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/caffeine-action.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ spec:
type: string
default: caffeine-cache
dependencies:
- "camel:core"
- "camel:caffeine"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/dns-dig-action.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ spec:
If the dns-type header won't be set, the DNS Type A will be used.
type: object
dependencies:
- "camel:core"
- "camel:dns"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/dns-ip-action.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ spec:
If the header won't be set the body will be used as domain to look for.
type: object
dependencies:
- "camel:core"
- "camel:dns"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/dns-lookup-action.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ spec:
out:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:jackson"
- "camel:dns"
- "camel:kamelet"
Expand Down
1 change: 1 addition & 0 deletions kamelets/dropbox-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ spec:
type: string
default: add
dependencies:
- "camel:core"
- "camel:dropbox"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/elasticsearch-index-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ spec:
in:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:jackson"
- "camel:kamelet"
- "camel:elasticsearch-rest"
Expand Down
1 change: 1 addition & 0 deletions kamelets/google-storage-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ spec:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: false
dependencies:
- "camel:core"
- "camel:kamelet"
- "camel:google-storage"
- "camel:jackson"
Expand Down
1 change: 1 addition & 0 deletions kamelets/kafka-not-secured-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ spec:
description: Comma separated list of Kafka Broker URLs
type: string
dependencies:
- "camel:core"
- "camel:kafka"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/kafka-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ spec:
- urn:alm:descriptor:com.tectonic.ui:password
- urn:camel:group:credentials
dependencies:
- "camel:core"
- "camel:kafka"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/minio-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ spec:
- 'urn:alm:descriptor:com.tectonic.ui:checkbox'
default: false
dependencies:
- "camel:core"
- "camel:minio"
- "camel:kamelet"
flow:
Expand Down
1 change: 1 addition & 0 deletions kamelets/mongodb-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ spec:
in:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:kamelet"
- "camel:mongodb"
- "camel:jackson"
Expand Down
1 change: 1 addition & 0 deletions kamelets/telegram-sink.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ spec:
out:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:jackson"
- "camel:kamelet"
- "camel:telegram"
Expand Down
1 change: 1 addition & 0 deletions kamelets/wttrin-source.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ spec:
out:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:http"
- "camel:jackson"
- "camel:jsonpath"
Expand Down
14 changes: 4 additions & 10 deletions script/validator/go.mod
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@
module github.com/apache/camel-kamelets/docs/generator

go 1.14
go 1.16

require (
github.com/apache/camel-k v1.4.0
github.com/apache/camel-k/pkg/apis/camel v1.4.0
github.com/apache/camel-k v1.8.0
github.com/apache/camel-k/pkg/apis/camel v1.8.0
github.com/bbalet/stopwords v1.0.0
github.com/pkg/errors v0.9.1
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
k8s.io/apimachinery v0.20.1
)

replace (
k8s.io/api => k8s.io/api v0.19.8
k8s.io/apimachinery => k8s.io/apimachinery v0.19.8
k8s.io/client-go => k8s.io/client-go v0.19.8
k8s.io/apimachinery v0.21.4
)
Loading

0 comments on commit 64fd5fb

Please sign in to comment.