github.com/smartcontractkit/chainlink-testing-framework/libs@v0.0.0-20240227141906-ec710b4eb1a3/charts/geth-prysm/install.sh (about)

     1  #!/bin/sh
     2  # Delete PVC and PV
     3  PVC_NAME="chain-state-claim"
     4  PV_NAME="chain-state-storage"
     5  kubectl delete pvc $PVC_NAME
     6  kubectl delete pv $PV_NAME
     7  
     8  param=$1
     9  
    10  if [ -n "$param" ]; then
    11    values_file="Values-$param.yaml"
    12  else
    13    values_file="Values.yaml"
    14  fi
    15  
    16  # Run helm lint
    17  if ! helm lint . -f ./$values_file; then
    18    echo "Helm lint failed. Exiting."
    19    exit 1
    20  fi
    21  
    22  # Package the Helm chart in the current directory
    23  helm package .
    24  
    25  # Get the name of the generated chart package
    26  chart_package=$(ls -1 | grep '.tgz')
    27  
    28  if [ -z "$chart_package" ]; then
    29    echo "No Helm chart package found."
    30    exit 1
    31  fi
    32  
    33  deployment_name=$2
    34  if [ -z "$deployment_name" ]; then
    35    # If deployment name is empty, use --generate-name
    36    deployment_name="--generate-name"
    37  fi
    38  
    39  # Install the newly generated chart package
    40  helm install "$deployment_name" "$chart_package" -f ./$values_file