diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 09360d9..cbc74ae 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -214,6 +214,13 @@ jobs: sed -i "s/^appVersion:.*/appVersion: \"${{ needs.extract-versions.outputs.app_version }}\"/" deploy/quix-environment-operator/Chart.yaml echo "Updated chart version to ${{ needs.extract-versions.outputs.chart_version }}" cat deploy/quix-environment-operator/Chart.yaml + + - name: Add CRD Manifests + run: | + make setup-dev + make manifests + mkdir -p deploy/quix-environment-operator/templates/crd-manifests/ + cp config/crd/bases/*.yaml deploy/quix-environment-operator/templates/crd-manifests/ - name: Verify values.yaml image tag run: | @@ -237,11 +244,26 @@ jobs: package-path: .cr-release-packages EOF - - name: Run chart-releaser + - name: Run chart-releaser (main branch) + if: github.ref_name == 'main' + uses: helm/chart-releaser-action@v1.7.0 + with: + charts_dir: deploy + config: cr.yaml + mark_as_latest: true + env: + CR_TOKEN: ${{ secrets.GITHUB_TOKEN }} + CR_SKIP_EXISTING: "true" + CR_FORCE: "true" + CR_PAGES_BRANCH: "gh-pages" + + - name: Run chart-releaser (other branches) + if: github.ref_name != 'main' uses: helm/chart-releaser-action@v1.7.0 with: charts_dir: deploy config: cr.yaml + mark_as_latest: false env: CR_TOKEN: ${{ secrets.GITHUB_TOKEN }} CR_SKIP_EXISTING: "true" @@ -284,13 +306,12 @@ jobs: # Make sure charts dir exists and package before switching branch if [ -d "deploy/quix-environment-operator" ]; then + # Package the finished chart helm package deploy/quix-environment-operator -d .cr-release-packages else - # Fallback to look for the chart elsewhere - find . -name Chart.yaml -exec dirname {} \; | while read chart_dir; do - echo "Found chart at: ${chart_dir}" - helm package ${chart_dir} -d .cr-release-packages - done + echo "Error: No charts were found" + exit 1 + fi # Make sure we actually packaged something diff --git a/README.md b/README.md index d633c9e..615fe7e 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,16 @@ A Kubernetes controller for secure, declarative provisioning of isolated applica Packaged as a Helm chart for customer-managed Kubernetes clusters. Operates within pre-approved RBAC constraints. +Install a specific version +``` +operator_version=0.1.2 +operator_env_regex="" +helm repo add quix-environment-operator https://quixio.github.io/quix-environment-operator/ && helm repo update +helm pull quix-environment-operator/quix-environment-operator --version $operator_version +helm upgrade --install quix-environment-operator -n quix-operator --create-namespace ./quix-environment-operator-$operator_version.tgz --set env.environmentRegex="$operator_env_regex" +``` +For all configuration options see [values.yaml](deploy/quix-environment-operator/values.yaml). + ## Development ### Setup diff --git a/deploy/quix-environment-operator/Chart.yaml b/deploy/quix-environment-operator/Chart.yaml index 58396f5..c69c4de 100644 --- a/deploy/quix-environment-operator/Chart.yaml +++ b/deploy/quix-environment-operator/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: quix-environment-operator description: A Kubernetes operator for provisioning isolated application environments type: application -version: 0.1.1 +version: 0.1.2 appVersion: "0.1.0" icon: https://quixstorageaccount.blob.core.windows.net/portal/img/quix_favicon.png keywords: diff --git a/deploy/quix-environment-operator/values.yaml b/deploy/quix-environment-operator/values.yaml index 25f8040..e7ddf7f 100644 --- a/deploy/quix-environment-operator/values.yaml +++ b/deploy/quix-environment-operator/values.yaml @@ -27,11 +27,11 @@ securityContext: {} resources: limits: - cpu: 200m - memory: 128Mi - requests: cpu: 100m - memory: 64Mi + memory: 96Mi + requests: + cpu: 25m + memory: 32Mi nodeSelector: {}