This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
dagger/pkg/alpha.dagger.io/kubernetes/helm/tests/helm.cue
Andrea Luzzardi 282759c0e5 cue modules: move stdlib to pkg/alpha.dagger.io
In preparation for Europa, we will vendor multiple CUE modules:

- `pkg/alpha.dagger.io`: legacy non-europa packages
- `pkg/dagger.io`: core Europa packages
- `pkg/universe.dagger.io`: Europa universe

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2022-01-11 13:16:37 -08:00

58 lines
1.1 KiB
CUE

package helm
import (
"alpha.dagger.io/random"
"alpha.dagger.io/dagger"
)
// We assume that a kinD cluster is running locally
// To deploy a local KinD cluster, follow this link : https://kind.sigs.k8s.io/docs/user/quick-start/
TestKubeconfig: dagger.#Input & {string}
TestChartSource: dagger.#Input & {dagger.#Artifact}
// Deploy user local chart
TestHelmSimpleChart: {
suffix: random.#String & {
seed: "simple"
length: 5
}
// Deploy chart
deploy: #Chart & {
name: "dagger-test-inline-\(suffix.out)"
namespace: "dagger-test"
kubeconfig: TestKubeconfig
chartSource: TestChartSource
}
// Verify deployment
verify: #VerifyHelm & {
chartName: deploy.name
namespace: deploy.namespace
}
}
// Deploy remote chart
TestHelmRepoChart: {
suffix: random.#String & {
seed: "repo"
length: 5
}
// Deploy remote chart
deploy: #Chart & {
name: "dagger-test-repository-\(suffix.out)"
namespace: "dagger-test"
kubeconfig: TestKubeconfig
repository: "https://charts.bitnami.com/bitnami"
chart: "redis"
}
// Verify deployment
verify: #VerifyHelm & {
chartName: deploy.name
namespace: deploy.namespace
}
}