diff --git a/tests/templates/kuttl/logging/03-create-configmap-with-prepared-logs.yaml b/tests/templates/kuttl/logging/03-create-configmap-with-prepared-logs.yaml new file mode 100644 index 00000000..df6308c2 --- /dev/null +++ b/tests/templates/kuttl/logging/03-create-configmap-with-prepared-logs.yaml @@ -0,0 +1,8 @@ +--- +apiVersion: kuttl.dev/v1beta1 +kind: TestStep +commands: + - script: > + kubectl create configmap prepared-logs + --from-file=prepared-logs.log4j2.xml + --namespace=$NAMESPACE diff --git a/tests/templates/kuttl/logging/03-assert.yaml b/tests/templates/kuttl/logging/04-assert.yaml similarity index 100% rename from tests/templates/kuttl/logging/03-assert.yaml rename to tests/templates/kuttl/logging/04-assert.yaml diff --git a/tests/templates/kuttl/logging/04-copy-prepared-logs.yaml b/tests/templates/kuttl/logging/04-copy-prepared-logs.yaml deleted file mode 100644 index b857ee70..00000000 --- a/tests/templates/kuttl/logging/04-copy-prepared-logs.yaml +++ /dev/null @@ -1,8 +0,0 @@ ---- -apiVersion: kuttl.dev/v1beta1 -kind: TestStep -commands: - - script: > - kubectl cp ./prepared-logs.log4j2.xml - $NAMESPACE/test-hive-metastore-automatic-log-config-0:/stackable/log/hive/prepared-logs.log4j2.xml - --container vector diff --git a/tests/templates/kuttl/logging/03-install-hive.yaml.j2 b/tests/templates/kuttl/logging/04-install-hive.yaml.j2 similarity index 89% rename from tests/templates/kuttl/logging/03-install-hive.yaml.j2 rename to tests/templates/kuttl/logging/04-install-hive.yaml.j2 index 396e340c..571f73f6 100644 --- a/tests/templates/kuttl/logging/03-install-hive.yaml.j2 +++ b/tests/templates/kuttl/logging/04-install-hive.yaml.j2 @@ -78,6 +78,17 @@ spec: loggers: ROOT: level: INFO + podOverrides: + spec: + containers: + - name: vector + volumeMounts: + - name: prepared-logs + mountPath: /stackable/log/prepared-logs + volumes: + - name: prepared-logs + configMap: + name: prepared-logs custom-log-config: replicas: 1 config: