Skip to content

Commit 1654fd9

Browse files
ArthurSensroboquat
authored andcommitted
Install CRDs before creating the observability stack
Signed-off-by: ArthurSens <[email protected]>
1 parent b3057df commit 1654fd9

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.werft/observability/monitoring-satellite.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,11 @@ export class MonitoringSatelliteInstaller {
6363
if (installationMethod == "observability-installer") {
6464
// As YAML is indentation sensitive we're using json instead so we don't have to worry about
6565
// getting the indentation right when formatting the code in TypeScript.
66-
const observabilityInstallerRenderCmd = `cd observability && make generate && ./hack/deploy-crds.sh --kubeconfig ${this.options.kubeconfigPath} && cd installer && echo '
66+
const observabilityInstallerRenderCmd = `cd observability && \
67+
make generate && \
68+
./hack/deploy-crds.sh --kubeconfig ${this.options.kubeconfigPath} && \
69+
kubectl create ns monitoring-satellite --kubeconfig ${this.options.kubeconfigPath} || true && \
70+
cd installer && echo '
6771
{
6872
"alerting": {
6973
"config": {}
@@ -88,7 +92,7 @@ export class MonitoringSatelliteInstaller {
8892
"enableFeatures": []
8993
}
9094
}' | go run main.go render --config - | kubectl --kubeconfig ${this.options.kubeconfigPath} apply -f -`;
91-
const renderingResult = exec(observabilityInstallerRenderCmd, { silent: true, dontCheckRc: true});
95+
const renderingResult = exec(observabilityInstallerRenderCmd, { silent: false, dontCheckRc: true});
9296
if (renderingResult.code > 0) {
9397
const err = new Error(`Failed rendering YAML with exit code ${renderingResult.code}`)
9498
renderingResult.stderr.split('\n').forEach(stderrLine => werft.log(sliceName, stderrLine))

0 commit comments

Comments
 (0)