Skip to content

Commit

Permalink
[Fix] : Failing Workflow test-chart.yaml (#154)
Browse files Browse the repository at this point in the history
* fix the release of chart

Signed-off-by: Shubham Gupta <[email protected]>

* remove the ./

Signed-off-by: Shubham Gupta <[email protected]>

* fix the install

Signed-off-by: Shubham Gupta <[email protected]>

* only install redis

Signed-off-by: Shubham Gupta <[email protected]>

* fix

Signed-off-by: Shubham Gupta <[email protected]>

---------

Signed-off-by: Shubham Gupta <[email protected]>
  • Loading branch information
shubham-cmyk authored Oct 12, 2023
1 parent 571b5ee commit 969264f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 32 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ jobs:

- name: Package and Release Charts
run: |
CHARTS=("elasticsearch" "k8s-vault-webhook" "logging-operator" "mongodb" "mongodb-cluster" "mongodb-operator" "mysql" "redis" "redis-cluster" "redis-operator" "redis-replication" "redis-sentinel" "fluentd" "kibana")
for CHART in "${CHARTS[@]}"; do
for CHART_DIR in $(find charts -maxdepth 1 -type d | tail --lines +2); do
CHART=$(basename $CHART_DIR)
echo "Packaging $CHART..."
helm package charts/$CHART
helm package $CHART_DIR
done
- name: Run chart-releaser
Expand Down
38 changes: 9 additions & 29 deletions .github/workflows/test-charts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,48 +10,28 @@ jobs:
- name: Check out code
uses: actions/checkout@v2

- name: Install Kind
uses: helm/[email protected]
- name: Create k8s Kind Cluster
uses: helm/[email protected]
with:
cluster_name: kind

- name: Install Helm
uses: azure/setup-helm@v1
uses: azure/setup-helm@v3
with:
version: '3.6.0'

- name: Create Kind Cluster
run: |
kind create cluster
version: v3.5.4

- name: Install yq
run: |
sudo snap install yq
- name: Install cert-manager CRDs and Helm Chart
run: |
helm repo add jetstack https://charts.jetstack.io
helm repo update
helm install cert-manager jetstack/cert-manager \
--namespace cert-manager \
--create-namespace \
--version v1.5.3 \
--set installCRDs=true
- name: Ensure cert-manager is fully deployed
run: |
kubectl rollout status deploy/cert-manager -n cert-manager
kubectl rollout status deploy/cert-manager-cainjector -n cert-manager
kubectl rollout status deploy/cert-manager-webhook -n cert-manager
- name: Install and test Redis Related Helm charts
run: |
kubectl cluster-info --context kind-kind
chart_dirs=("redis-operator" "redis" "redis-cluster" "redis-replication" "redis-sentinel")
for dir in "${chart_dirs[@]}"
for CHART_DIR in $(find charts -maxdepth 1 -type d | tail -n +2 | grep "^charts/redis")
do
chart_version=$(yq e .version ./charts/$dir/Chart.yaml)
chart_version=$(yq e .version $CHART_DIR/Chart.yaml)
echo "Installing $dir chart with version $chart_version..."
helm install $dir ./charts/$dir/ --version $chart_version
helm install $(basename $CHART_DIR) $CHART_DIR/
helm test $dir
done
echo "Listing installed Helm charts..."
Expand Down

0 comments on commit 969264f

Please sign in to comment.