diff --git a/dogfood/Dockerfile b/dogfood/Dockerfile index d25a0c3b3764f..34ea4d5aaaf27 100644 --- a/dogfood/Dockerfile +++ b/dogfood/Dockerfile @@ -159,7 +159,8 @@ RUN apt-get update --quiet && apt-get install --yes \ terraform \ fish \ unzip \ - zstd && \ + zstd \ + gettext-base && \ # Delete package cache to avoid consuming space in layer apt-get clean && \ # Configure FIPS-compliant policies diff --git a/scaletest/README.md b/scaletest/README.md index b9cf1b429fae8..9c80e035440ee 100644 --- a/scaletest/README.md +++ b/scaletest/README.md @@ -46,7 +46,14 @@ All of the above arguments may be specified as environment variables. Consult th ### Prometheus Metrics -To capture Prometheus metrics from the loadtest, two environment +To capture Prometheus metrics from the loadtest, two environment variables are required: + +- `SCALETEST_PROMETHEUS_REMOTE_WRITE_USER` +- `SCALETEST_PROMETHEUS_REMOTE_WRITE_PASSWORD` + +### Enterprise License + +To add an Enterprise license, set the `SCALETEST_CODER_LICENSE` environment variable to the JWT string ## Scenarios diff --git a/scaletest/scaletest.sh b/scaletest/scaletest.sh index 83111a3a11425..9db7d5a123e74 100755 --- a/scaletest/scaletest.sh +++ b/scaletest/scaletest.sh @@ -14,6 +14,7 @@ SCALETEST_SCENARIO="${SCALETEST_SCENARIO:-}" SCALETEST_PROJECT="${SCALETEST_PROJECT:-}" SCALETEST_PROMETHEUS_REMOTE_WRITE_USER="${SCALETEST_PROMETHEUS_REMOTE_WRITE_USER:-}" SCALETEST_PROMETHEUS_REMOTE_WRITE_PASSWORD="${SCALETEST_PROMETHEUS_REMOTE_WRITE_PASSWORD:-}" +SCALETEST_CODER_LICENSE="${SCALETEST_CODER_LICENSE:-}" SCALETEST_SKIP_CLEANUP="${SCALETEST_SKIP_CLEANUP:-0}" SCALETEST_CREATE_CONCURRENCY="${SCALETEST_CREATE_CONCURRENCY:-10}" SCALETEST_TRAFFIC_BYTES_PER_TICK="${SCALETEST_TRAFFIC_BYTES_PER_TICK:-1024}" @@ -155,6 +156,11 @@ maybedryrun "$DRY_RUN" kubectl --kubeconfig="${KUBECONFIG}" -n "coder-${SCALETES echo "Initializing Coder deployment." DRY_RUN="$DRY_RUN" "${PROJECT_ROOT}/scaletest/lib/coder_init.sh" "${SCALETEST_CODER_URL}" +if [[ -n "${SCALETEST_CODER_LICENSE}" ]]; then + echo "Applying Coder Enterprise License" + DRY_RUN="$DRY_RUN" "${PROJECT_ROOT}/scaletest/lib/coder_shim.sh" license add -l "${SCALETEST_CODER_LICENSE}" +fi + echo "Creating ${SCALETEST_NUM_WORKSPACES} workspaces." DRY_RUN="$DRY_RUN" "${PROJECT_ROOT}/scaletest/lib/coder_shim.sh" scaletest create-workspaces \ --count "${SCALETEST_NUM_WORKSPACES}" \ diff --git a/scaletest/terraform/coder.tf b/scaletest/terraform/coder.tf index fe7e84374042c..f24e7299f4951 100644 --- a/scaletest/terraform/coder.tf +++ b/scaletest/terraform/coder.tf @@ -106,6 +106,8 @@ coder: value: "true" - name: "CODER_VERBOSE" value: "true" + - name: "CODER_EXPERIMENTS" + value: "${var.coder_experiments}" image: repo: ${var.coder_image_repo} tag: ${var.coder_image_tag} diff --git a/scaletest/terraform/prometheus.tf b/scaletest/terraform/prometheus.tf index 4c6f082e1c345..900ad83dd2fc7 100644 --- a/scaletest/terraform/prometheus.tf +++ b/scaletest/terraform/prometheus.tf @@ -112,6 +112,7 @@ resource "kubernetes_secret" "prometheus-postgres-password" { # Install Prometheus Postgres exporter helm chart resource "helm_release" "prometheus-exporter-chart" { + depends_on = [helm_release.prometheus-chart] repository = local.prometheus_exporter_helm_repo chart = local.prometheus_exporter_helm_chart name = local.prometheus_exporter_release_name diff --git a/scaletest/terraform/vars.tf b/scaletest/terraform/vars.tf index 41c83be84348c..6b51425b92af0 100644 --- a/scaletest/terraform/vars.tf +++ b/scaletest/terraform/vars.tf @@ -157,3 +157,8 @@ variable "prometheus_remote_write_send_interval" { description = "Prometheus remote write interval." default = "15s" } + +variable "coder_experiments" { + description = "Coder Experiments to enable" + default = "" +}