From db835d3c9ba749f4786f1167d03cd697c341eb65 Mon Sep 17 00:00:00 2001 From: flbla Date: Wed, 17 Apr 2024 10:04:48 +0200 Subject: [PATCH] improve acc tests Signed-off-by: flbla --- .github/workflows/test.yml | 41 +++++++++++++++++++------------------- README.md | 16 +++++++++++++++ 2 files changed, 37 insertions(+), 20 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9a8214a8..1f0fd54e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -6,9 +6,18 @@ on: pull_request: paths-ignore: - 'README.md' + - 'docs/**' + - 'examples/**' + - 'templates/**' push: + branches: + - main + - "release/**" paths-ignore: - 'README.md' + - 'docs/**' + - 'examples/**' + - 'templates/**' # For systems with an upstream API that could drift unexpectedly (like most SaaS systems, etc.), # we recommend testing at a regular interval not necessarily tied to code changes. This will # ensure you are alerted to something breaking due to an API change, even if the code did not @@ -72,42 +81,34 @@ jobs: matrix: # list whatever Terraform versions here you would like to support terraform: - - '0.15.*' - - '1.0.*' - - '1.1.*' - - '1.2.*' - - '1.3.*' - - '1.4.*' - - '1.5.*' + - '1.6.*' + - '1.7.*' + - '1.8.*' + harbor: + - '1.14.*' # harbor 2.10 + - '1.13.*' # harbor 2.9 + - '1.12.*' # harbor 2.8 steps: - name: Check out code into the Go module directory uses: actions/checkout@v4 - - - name: Setup Docker - uses: docker-practice/actions-setup-docker@v1 - with: - docker_version: "24.0" - docker_channel: stable - docker_daemon_json: '{"insecure-registries":["0.0.0.0/0"]}' - name: Create kind cluster uses: helm/kind-action@v1.9.0 with: - version: v0.20.0 - node_image: kindest/node:v1.28.0 - cluster_name: kind-cluster-v1.28.0 + version: v0.21.0 + node_image: kindest/node:v1.29.0 + cluster_name: kind-cluster-v1.29.0 config: kind-cluster.yaml - name: Install Nginx ingress controller run: | - kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v1.0.3/deploy/static/provider/kind/deploy.yaml + kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v1.10.0/deploy/static/provider/kind/deploy.yaml kubectl wait --namespace ingress-nginx --for=condition=ready pod --selector=app.kubernetes.io/component=controller --timeout=120s - uses: azure/setup-helm@v4 with: version: 'latest' # default is latest (stable) - token: ${{ secrets.GITHUB_TOKEN }} # only needed if version is 'latest' id: install - name: Install Harbor Helm chart @@ -118,7 +119,7 @@ jobs: --set expose.tls.enabled="false" \ --set expose.ingress.hosts.core="harbor.local" \ --set expose.ingress.hosts.notary="harbor.local" \ - harbor/harbor + harbor/harbor --version ${{ matrix.harbor }} - name: Set /etc/hosts run: | diff --git a/README.md b/README.md index 006e3b84..401d8fa0 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,22 @@ Configure and manage Harbor with Terraform and [Pulumi](https://github.com/pulum ## Usage [See the docs for usage information](./docs). +## Compatibility and Acceptance Tests + +Our acceptance tests are run against specific versions of Harbor and Terraform to ensure compatibility. +For the latest version of the provider, we ran the tests against the following versions of Harbor and Terraform: +### Harbor Versions +- `2.8` +- `2.9` +- `2.10` + +### Terraform Versions +- `1.6` +- `1.7` +- `1.8` + +Please note that while we strive to maintain compatibility with these versions, we recommend always using the latest versions of Harbor and Terraform for the best experience. + ## Contributing Everyone is welcome to contribute to this repository. Feel free to raise [issues](https://github.com/goharbor/terraform-provider-harbor/issues) or to submit [Pull Requests.](https://github.com/goharbor/terraform-provider-harbor/pulls)