Skip to content

Commit

Permalink
sync test and extensions, improve downloading of kyma
Browse files Browse the repository at this point in the history
  • Loading branch information
dbadura committed Sep 9, 2024
1 parent e3ba124 commit c87ad8e
Show file tree
Hide file tree
Showing 19 changed files with 532 additions and 140 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
.git
.github
kyma/temp
bin
13 changes: 13 additions & 0 deletions .github/scripts/kyma.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
PROJECT_ROOT=./
LOCALBIN ?= $(realpath $(PROJECT_ROOT))/bin
$(LOCALBIN):
mkdir -p $(LOCALBIN)


KYMA ?= $(LOCALBIN)/kyma
kyma: $(LOCALBIN) $(KYMA) ## Download kyma locally if necessary.
$(KYMA):
echo $(LOCALBIN)
$(eval OS=$(shell (uname -s | tr 'A-Z' 'a-z')))
curl --location --output $(LOCALBIN)/kyma https://storage.googleapis.com/kyma-cli-unstable/kyma-${OS}
chmod +x $(LOCALBIN)/kyma
11 changes: 1 addition & 10 deletions .github/scripts/setup-kyma.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
#!/bin/bash

set -e
OS="$(uname -s | tr 'A-Z' 'a-z')"

APPLICATION_CONNECTOR_VERSION="1.1.3"

echo "Using OS:" ${OS}
mkdir bin
curl --location --output ./bin/kyma https://storage.googleapis.com/kyma-cli-unstable/kyma-${OS}
chmod +x ./bin/kyma
make --makefile ./.github/scripts/kyma.mk kyma

echo "Provisioning k3d cluster for Kyma"
k3d registry create kyma-registry --port 5001
Expand Down Expand Up @@ -43,11 +39,6 @@ kubectl apply -f https://github.com/kyma-project/application-connector-manager/r
echo "Apply eventing"
kubectl apply -f https://github.com/kyma-project/eventing-manager/releases/latest/download/eventing-manager.yaml

echo "Apply module templates"
kubectl apply -f ./kyma-envs/extensions/modules/api-gateway-regular.yaml
kubectl apply -f ./kyma-envs/extensions/modules/eventing-fast.yaml
kubectl apply -f ./kyma-envs/extensions/modules/eventing-regular.yaml

echo "Apply and enable telemetry module"
kubectl apply -f https://github.com/kyma-project/telemetry-manager/releases/latest/download/telemetry-manager.yaml
kubectl apply -f https://github.com/kyma-project/telemetry-manager/releases/latest/download/telemetry-default-cr.yaml -n kyma-system
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ tests/integration/fixtures/kubeconfig.yaml
tests/integration/fixtures/kubeconfig-k3s.yaml
tests/integration/fixtures/sa-kubeconfig.yaml

tests/kyma/cypress/*
tests/kyma/fixtures/kubeconfig.yaml

public/themes/@sap-theming/*.css

public/environments
Expand Down
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,5 @@ backend/backend-production.*
**/public/**

tests/integration/fixtures/kubeconfig.yaml
tests/kyma/fixtures/kubeconfig.yaml
kyma/**
163 changes: 142 additions & 21 deletions kyma/extensions/configuration/certificates.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,42 +8,148 @@ metadata:
busola.io/extension: resource
busola.io/extension-version: '0.5'
data:
dataSources: |-
jksSecret:
resource:
kind: Secret
version: v1
filter: $item.metadata.name = $root.spec.keystores.jks.passwordSecretRef.secretName
pkcs12Secret:
resource:
kind: Secret
version: v1
filter: $item.metadata.name = $root.spec.keystores.pkcs12.passwordSecretRef.secretName
details: |
header:
- name: status
source: 'status.state ? status.state : "UNKNOWN"'
highlights:
unknown:
- UNKNOWN
widget: Badge
description: status.message
- name: status.expirationDate
source: '$readableTimestamp(status.expirationDate)'
- name: commonName
source: spec.commonName
status:
header:
- name: status
source: 'status.state ? status.state : "UNKNOWN"'
highlights:
unknown:
- UNKNOWN
widget: Badge
description: status.message
body:
- name: conditions
source: status.conditions
widget: ConditionList
- name: status.expirationDate
source: '$readableTimestamp(status.expirationDate)'
- name: issuer
source: status.issuerRef.name
- name: Observed Generation
source: status.observedGeneration
body:
- name: references
- name: Specification
widget: Panel
children:
- name: issuer
source: status.issuerRef.name
source: spec.issuerRef.name
widget: ResourceLink
visibility: $exists(spec.issuerRef)
resource:
namespace: $root.spec.issuerRef.namespace
kind: "'Issuer'"
name: $root.spec.issuerRef.name
- name: secret
source: spec.secretRef.name
widget: ResourceLink
resource:
namespace: $root.spec.secretRef.namespace
kind: "'Secret'"
name: $root.spec.secretRef.name
- name: spec.secretName
source: spec.secretName
visibility: $exists(spec.secretName) and $not($exists(spec.secretRef))
- name: spec.secretLabels
source: spec.secretLabels
visibility: $exists(spec.secretLabels)
- name: commonName
source: spec.commonName
- name: dnsNames
source: spec.dnsNames
widget: Labels
- name: spec.csr
source: spec.csr
- name: metadata.annotations
source: metadata.annotations
widget: Labels
- name: spec.followCNAME
source: spec.followCNAME
visibility: $exists(spec.followCNAME)
- name: spec.renew
source: spec.renew
- name: spec.dnsNames
source: spec.dnsNames
widget: Labels
- name: spec.ensureRenewedAfter
source: spec.ensureRenewedAfter
visibility: $exists(spec.ensureRenewedAfter)
- name: spec.preferredChain
source: spec.preferredChain
visibility: $exists(spec.preferredChain)
- name: spec.keystores
widget: Panel
visibility: $exists(spec.keystores)
children:
- name: JKS
widget: Panel
visibility: $exists(spec.keystores.jks)
children:
- name: spec.keystores.create
source: spec.keystores.jks.create
visibility: $exists(spec.keystores.jks.create)
- name: spec.keystores.passwordSecretRef
widget: Panel
visibility: $exists(spec.keystores.jks.passwordSecretRef)
children:
- name: Password Secret Ref
source: spec.keystores.jks.passwordSecretRef.secretName
widget: ResourceLink
visibility: $exists(spec.keystores.jks.passwordSecretRef.secretName) and $count($jksSecret().items)>0
resource:
namespace: $jksSecret().items.metadata.namespace
kind: "'Secret'"
name: $root.spec.keystores.jks.passwordSecretRef.secretName
- name: spec.keystores.secretName
source: spec.keystores.jks.passwordSecretRef.secretName
visibility: $exists(spec.keystores.jks.passwordSecretRef.secretName) and $count($jksSecret().items)=0
- name: spec.keystores.key
source: spec.keystores.jks.passwordSecretRef.key
visibility: $exists(spec.keystores.jks.passwordSecretRef.key)
- name: PKCS12
widget: Panel
visibility: $exists(spec.keystores.pkcs12)
children:
- name: Create
source: spec.keystores.pkcs12.create
visibility: $exists(spec.keystores.pkcs12.create)
- name: spec.keystores.passwordSecretRef
widget: Panel
visibility: $exists(spec.keystores.pkcs12.passwordSecretRef)
children:
- name: Password Secret Ref
source: spec.keystores.pkcs12.passwordSecretRef.secretName
widget: ResourceLink
visibility: $exists(spec.keystores.pkcs12.passwordSecretRef.secretName) and $count($pkcs12Secret().items)>0
resource:
namespace: $pkcs12Secret().items.metadata.namespace
kind: "'Secret'"
name: $root.spec.keystores.pkcs12.passwordSecretRef.secretName
- name: spec.keystores.secretName
source: spec.keystores.pkcs12.passwordSecretRef.secretName
visibility: $exists(spec.keystores.pkcs12.passwordSecretRef.secretName) and $count($pkcs12Secret().items)=0
- name: spec.keystores.key
source: spec.keystores.pkcs12.passwordSecretRef.key
visibility: $exists(spec.keystores.pkcs12.passwordSecretRef.key)
- name: spec.privateKey
widget: Panel
visibility: $exists(spec.privateKey)
children:
- name: spec.privateKey.algorithm
source: spec.privateKey.algorithm
visibility: $exists(spec.privateKey.algorithm)
- name: spec.privateKey.size
source: spec.privateKey.size
visibility: $exists(spec.privateKey.size)
- widget: EventList
name: Events
filter: "$matchEvents($$, $root.kind, $root.metadata.name)"
hideInvolvedObjects: true
form: |
- var: useCSR
dynamicValue: '$exists(spec.csr)'
Expand Down Expand Up @@ -139,17 +245,32 @@ data:
metadata.creationTimestamp: Created at
status: Status
status.expirationDate: Expiration Time
conditions.conditions: Conditions
issuer: Issuer
commonName: Common Name
spec.secretRef: Secret to use
spec.useExisting: Use the existing Secret
spec.additionalDomains: Additional domain names, one per line
spec.dnsNames: DNS Names
dnsNames: DNS Names
spec.csr: CSR
spec.useCSR: Use a CSR
spec.certSignReq: Plain text Certificate Signing Request
spec.certSignReqDecoded: Base64-encoded Certificate Signing Request
spec.followCNAME: Follow CNAME
spec.keystores: Keystores
spec.keystores.create: Create
spec.keystores.passwordSecretRef: Password Secret Ref
spec.keystores.secretName: Secret Name
spec.keystores.key: Key
spec.privateKey: Private Key
spec.privateKey.algorithm: Algorithm
spec.privateKey.size: Size
spec.renew: Renew
spec.ensureRenewedAfter: Ensure Renewed After
spec.preferredChain: Preferred Chain
spec.secretLabels: Secret Labels
spec.secretName: Secret Name
certificateCN: Certificate CN (max 64 characters)
references: References
secret: Secret
conditions: Conditions
52 changes: 36 additions & 16 deletions kyma/extensions/configuration/dns-entries.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,40 @@ metadata:
busola.io/extension: resource
busola.io/extension-version: '0.5'
data:
dataSources: |-
targetServices:
resource:
kind: Service
version: v1
filter: >-
$exists($item.status.loadBalancer.ingress)
relatedService:
resource:
kind: Service
version: v1
filter: >-
$filter($root.spec.targets, function ($v, $i, $a) { $contains($item.status.loadBalancer.ingress.ip, $v)})
details: |-
header:
- source: 'status.state ? status.state : "UNKNOWN"'
highlights:
informative:
- UNKNOWN
type: string
name: status
widget: Badge
description: status.message
resourceGraph:
dataSources:
- source: relatedService
status:
header:
- source: 'status.state ? status.state : "UNKNOWN"'
highlights:
informative:
- UNKNOWN
type: string
name: status
widget: Badge
description: status.message
body:
- name: Provider
source: status.provider
fullWidth: true
- name: Observed Generation
source: status.observedGeneration
body:
- name: Provider
widget: Panel
children:
- name: Provider
source: status.provider
- name: Specification
widget: Panel
children:
Expand Down Expand Up @@ -51,8 +69,10 @@ data:
required: true
name: spec.targets
children:
- widget: Text
simple: true
- simple: true
enum: "$map($targetServices().items, function($v, $i, $a) {
{'key':$v.status.loadBalancer.ingress.ip , 'name':$v.status.loadBalancer.ingress.ip & ' (' & $v.metadata.name & ')'}
})"
placeholder: target.placeholder
- path: spec.text
name: spec.text
Expand Down
Loading

0 comments on commit c87ad8e

Please sign in to comment.