diff --git a/.github/workflows/pr-helm-chart-testing.yml.disabled.txt b/.github/workflows/pr-helm-chart-testing.yml similarity index 53% rename from .github/workflows/pr-helm-chart-testing.yml.disabled.txt rename to .github/workflows/pr-helm-chart-testing.yml index eeb1715b1c2..5b00303010d 100644 --- a/.github/workflows/pr-helm-chart-testing.yml.disabled.txt +++ b/.github/workflows/pr-helm-chart-testing.yml @@ -1,24 +1,20 @@ -# This workflow is intentionally disabled while we're still working on it -# It's close to ready, but a race condition needs to be fixed with -# API server and Vespa startup, and it needs to have a way to build/test against -# local containers - name: Helm - Lint and Test Charts on: merge_group: pull_request: branches: [ main ] - + workflow_dispatch: # Allows manual triggering + jobs: - lint-test: + helm-chart-check: # See https://runs-on.com/runners/linux/ runs-on: [runs-on,runner=8cpu-linux-x64,hdd=256,"run-id=${{ github.run_id }}"] # fetch-depth 0 is required for helm/chart-testing-action steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 @@ -28,7 +24,7 @@ jobs: version: v3.14.4 - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.11' cache: 'pip' @@ -45,24 +41,31 @@ jobs: - name: Set up chart-testing uses: helm/chart-testing-action@v2.6.1 + # even though we specify chart-dirs in ct.yaml, it isn't used by ct for the list-changed command... - name: Run chart-testing (list-changed) id: list-changed run: | - changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }}) + echo "default_branch: ${{ github.event.repository.default_branch }}" + changed=$(ct list-changed --remote origin --target-branch ${{ github.event.repository.default_branch }} --chart-dirs deployment/helm/charts) + echo "list-changed output: $changed" if [[ -n "$changed" ]]; then echo "changed=true" >> "$GITHUB_OUTPUT" fi + # lint all charts if any changes were detected - name: Run chart-testing (lint) -# if: steps.list-changed.outputs.changed == 'true' - run: ct lint --all --config ct.yaml --target-branch ${{ github.event.repository.default_branch }} + if: steps.list-changed.outputs.changed == 'true' + run: ct lint --config ct.yaml --all + # the following would lint only changed charts, but linting isn't expensive + # run: ct lint --config ct.yaml --target-branch ${{ github.event.repository.default_branch }} - name: Create kind cluster -# if: steps.list-changed.outputs.changed == 'true' + if: steps.list-changed.outputs.changed == 'true' uses: helm/kind-action@v1.10.0 - name: Run chart-testing (install) -# if: steps.list-changed.outputs.changed == 'true' - run: ct install --all --config ct.yaml -# run: ct install --target-branch ${{ github.event.repository.default_branch }} - \ No newline at end of file + if: steps.list-changed.outputs.changed == 'true' + run: ct install --all --helm-extra-set-args="--set=nginx.enabled=false" --debug --config ct.yaml + # the following would install only changed charts, but we only have one chart so + # don't worry about that for now + # run: ct install --target-branch ${{ github.event.repository.default_branch }} diff --git a/ct.yaml b/ct.yaml index 14c557d8f3f..f568ef5d52b 100644 --- a/ct.yaml +++ b/ct.yaml @@ -1,12 +1,18 @@ # See https://github.com/helm/chart-testing#configuration +# still have to specify this on the command line for list-changed chart-dirs: - deployment/helm/charts +# must be kept in sync with Chart.yaml chart-repos: - - vespa=https://unoplat.github.io/vespa-helm-charts + - vespa=https://danswer-ai.github.io/vespa-helm-charts - postgresql=https://charts.bitnami.com/bitnami -helm-extra-args: --timeout 600s +helm-extra-args: --debug --timeout 600s + +# nginx appears to not work on kind, likely due to lack of loadbalancer support +# helm-extra-set-args also only works on the command line, not in this yaml +# helm-extra-set-args: --set=nginx.enabled=false validate-maintainers: false diff --git a/deployment/helm/charts/danswer/Chart.lock b/deployment/helm/charts/danswer/Chart.lock index db7b18539ed..26cc24e4494 100644 --- a/deployment/helm/charts/danswer/Chart.lock +++ b/deployment/helm/charts/danswer/Chart.lock @@ -3,13 +3,13 @@ dependencies: repository: https://charts.bitnami.com/bitnami version: 14.3.1 - name: vespa - repository: https://unoplat.github.io/vespa-helm-charts - version: 0.2.3 + repository: https://danswer-ai.github.io/vespa-helm-charts + version: 0.2.16 - name: nginx repository: oci://registry-1.docker.io/bitnamicharts version: 15.14.0 - name: redis repository: https://charts.bitnami.com/bitnami version: 20.1.0 -digest: sha256:fb42426c1d13667a4929d0d6a7d681bf08120e4a4eb1d15437e4ec70920be3f8 -generated: "2024-09-11T09:16:03.312328-07:00" +digest: sha256:711bbb76ba6ab604a36c9bf1839ab6faa5610afb21e535afd933c78f2d102232 +generated: "2024-11-07T09:39:30.17171-08:00" diff --git a/deployment/helm/charts/danswer/Chart.yaml b/deployment/helm/charts/danswer/Chart.yaml index 4205546c6c3..8cda8e8ba2e 100644 --- a/deployment/helm/charts/danswer/Chart.yaml +++ b/deployment/helm/charts/danswer/Chart.yaml @@ -5,7 +5,7 @@ home: https://www.danswer.ai/ sources: - "https://github.com/danswer-ai/danswer" type: application -version: 0.2.0 +version: 0.2.1 appVersion: "latest" annotations: category: Productivity @@ -23,8 +23,8 @@ dependencies: repository: https://charts.bitnami.com/bitnami condition: postgresql.enabled - name: vespa - version: 0.2.3 - repository: https://unoplat.github.io/vespa-helm-charts + version: 0.2.16 + repository: https://danswer-ai.github.io/vespa-helm-charts condition: vespa.enabled - name: nginx version: 15.14.0 diff --git a/deployment/helm/charts/danswer/templates/configmap.yaml b/deployment/helm/charts/danswer/templates/configmap.yaml index 6236e1b62a4..e3cbf9d4c41 100755 --- a/deployment/helm/charts/danswer/templates/configmap.yaml +++ b/deployment/helm/charts/danswer/templates/configmap.yaml @@ -7,7 +7,7 @@ metadata: data: INTERNAL_URL: "http://{{ include "danswer-stack.fullname" . }}-api-service:{{ .Values.api.service.port | default 8080 }}" POSTGRES_HOST: {{ .Release.Name }}-postgresql - VESPA_HOST: "document-index-service" + VESPA_HOST: da-vespa-0.vespa-service REDIS_HOST: {{ .Release.Name }}-redis-master MODEL_SERVER_HOST: "{{ include "danswer-stack.fullname" . }}-inference-model-service" INDEXING_MODEL_SERVER_HOST: "{{ include "danswer-stack.fullname" . }}-indexing-model-service" diff --git a/deployment/helm/charts/danswer/templates/tests/test-connection.yaml b/deployment/helm/charts/danswer/templates/tests/test-connection.yaml index 60fbd1054c1..d3b57dd4354 100644 --- a/deployment/helm/charts/danswer/templates/tests/test-connection.yaml +++ b/deployment/helm/charts/danswer/templates/tests/test-connection.yaml @@ -11,5 +11,5 @@ spec: - name: wget image: busybox command: ['wget'] - args: ['{{ include "danswer-stack.fullname" . }}:{{ .Values.webserver.service.port }}'] + args: ['{{ include "danswer-stack.fullname" . }}-webserver:{{ .Values.webserver.service.port }}'] restartPolicy: Never