Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(greptimedb-cluster): e2e failed and release cluster chart to ACR failed #185

Merged
merged 3 commits into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ on:
branches:
- main
workflow_dispatch:
inputs:
release-charts-to-acr:
description: Release the Helm charts to ACR
required: false
default: 'false'

jobs:
release:
Expand Down Expand Up @@ -39,6 +44,7 @@ jobs:

release-charts-to-acr:
runs-on: ubuntu-latest
if: ${{ inputs.release-charts-to-acr == 'true' || github.event_name == 'push' }}
zyy17 marked this conversation as resolved.
Show resolved Hide resolved
steps:
- name: Check out code
uses: actions/checkout@v4
Expand Down
10 changes: 7 additions & 3 deletions scripts/e2e/greptimedb-cluster.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,12 @@ function drop_table() {
}

function deploy_greptimedb_cluster() {
helm upgrade --install mycluster greptimedb-cluster -n default
# Handle greptimedb-cluster dependencies.
helm repo add grafana https://grafana.github.io/helm-charts
helm dependency build charts/greptimedb-cluster

# Deploy greptimedb cluster.
helm upgrade --install mycluster charts/greptimedb-cluster -n default
zyy17 marked this conversation as resolved.
Show resolved Hide resolved

timeout=300
sleep_interval=5
Expand All @@ -76,8 +81,7 @@ function deploy_greptimedb_cluster() {
}

function deploy_greptimedb_operator() {
cd charts
helm upgrade --install greptimedb-operator greptimedb-operator -n default
helm upgrade --install greptimedb-operator charts/greptimedb-operator -n default
zyy17 marked this conversation as resolved.
Show resolved Hide resolved

# Wait for greptimedb operator to be ready
kubectl rollout status --timeout=60s deployment/greptimedb-operator -n default
Expand Down
4 changes: 2 additions & 2 deletions scripts/release/release-charts-to-acr.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ OCI_REGISTRY_URL=${OCI_REGISTRY_URL:-"greptime-registry.cn-hangzhou.cr.aliyuncs.
OCI_NAMESPACE=${OCI_NAMESPACE:-"charts"}
CHARTS_DIR="charts"

for dir in "$CHARTS_DIR"/*/; do
for dir in "$CHARTS_DIR"/*; do
# Ensure the directory exists and is not empty.
if [ -d "$dir" ]; then
# Get the chart name from the directory path.
Expand All @@ -22,7 +22,7 @@ for dir in "$CHARTS_DIR"/*/; do
helm package "$dir" --destination "$dir"

# Get the packaged chart file path.
packaged_file=$(find "$dir" -type f -name "*.tgz")
packaged_file=$(find "$dir" -type f -name "${chart_name}-*.tgz" -print -quit)

echo "Package $chart_name to $packaged_file and push to oci://$OCI_REGISTRY_URL/$OCI_NAMESPACE/$chart_name ..."

Expand Down
Loading