Skip to content

Commit

Permalink
test kind
Browse files Browse the repository at this point in the history
  • Loading branch information
gionn committed Jul 29, 2024
1 parent 8150a65 commit 519c050
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 0 deletions.
70 changes: 70 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,3 +91,73 @@ jobs:
quay_password: ${{ secrets.QUAY_PASSWORD }}

- uses: Alfresco/alfresco-build-tools/.github/actions/[email protected]

helm-test:
name: helm test
needs: build-test
runs-on: ubuntu-latest
steps:
- name: Download artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
path: /tmp
name: docker-images

- name: Setup cluster
uses: Alfresco/alfresco-build-tools/.github/actions/[email protected]
with:
ingress-nginx-ref: controller-v1.8.2
metrics: "true"

- name: Load Docker images
run: |
ls -1 /tmp/*.tar | xargs --no-run-if-empty -L 1 kind load image-archive
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7

- uses: azure/setup-helm@fe7b79cd5ee1e45176fcad797de68ecaf3ca4814
with:
version: "3.14.3"

- name: Login to Quay.io
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 # v3.1.0
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}

- name: Create registries auth secret
run: >-
kubectl create secret generic regcred
--from-file=.dockerconfigjson=$HOME/.docker/config.json
--type=kubernetes.io/dockerconfigjson
- name: Fetch upstream values for tests
working-directory: test/helm
run: >-
curl -L
https://raw.githubusercontent.com/Alfresco/acs-deployment/c1096488a9dd2bef4fe20f9677a14afba4fc8932/test/enterprise-integration-test-values.yaml
-o enterprise-integration-test-values.yaml
- name: Helm install
run: |
helm repo add alfresco https://kubernetes-charts.alfresco.com/stable
helm repo update
helm install acs alfresco/alfresco-content-services \
--set global.search.sharedSecret="$(openssl rand -hex 24)" \
--set global.known_urls=http://localhost \
--set global.alfrescoRegistryPullSecrets=regcred \
--values test/helm/enterprise-integration-test-values.yaml \
--values test/helm/test-overrides.yaml
- name: Spit cluster status after install
if: always()
run: |
helm ls --all-namespaces --all
helm status acs --show-resources
kubectl describe pod
- name: Run helm test
id: helm_test
run: helm test acs
22 changes: 22 additions & 0 deletions test/helm/test-overrides.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
alfresco-repository:
image:
repository: localhost/alfresco-content-repository
tag: latest
share:
alfresco-search-enterprise:
alfresco-transform-service:
pdfrenderer:
imagemagick:
libreoffice:
tika:
transformmisc:
transformrouter:
image:
repository: localhost/alfresco-transform-router
tag: latest
filestore:
image:
repository: localhost/alfresco-shared-file-store
tag: latest
alfresco-sync-service:

0 comments on commit 519c050

Please sign in to comment.