File tree Expand file tree Collapse file tree 2 files changed +10
-6
lines changed
Expand file tree Collapse file tree 2 files changed +10
-6
lines changed Original file line number Diff line number Diff line change 1313 description : ' Semver version (e.g., 2.3.4)'
1414 required : true
1515 type : string
16+ ref :
17+ description : ' Git ref to checkout'
18+ required : false
19+ type : string
1620 workflow_dispatch :
1721 inputs :
1822 network :
4145 - name : Determine checkout ref
4246 id : checkout-ref
4347 run : |
44- if [[ -n "${{ github.ref }}" ]]; then
45- echo "ref=${{ github.ref }}" >> $GITHUB_OUTPUT
46- elif [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
47- echo "ref=${{ github.ref_name }}" >> $GITHUB_OUTPUT
48+ # Use inputs.ref if provided (workflow_call), otherwise use github.ref
49+ if [[ -n "${{ inputs.ref }}" ]]; then
50+ echo "ref=${{ inputs.ref }}" >> $GITHUB_OUTPUT
4851 else
4952 echo "ref=${{ github.ref }}" >> $GITHUB_OUTPUT
5053 fi
Original file line number Diff line number Diff line change 6464
6565# Install GKE auth plugin for kubectl
6666if command -v gcloud & > /dev/null; then
67+ echo " We have gcloud"
6768 # Check if GKE auth plugin is already installed
6869 if command -v gke-gcloud-auth-plugin & > /dev/null ||
6970 gcloud components list --filter=" id:gke-gcloud-auth-plugin" --format=" value(state.name)" 2> /dev/null | grep -q " Installed" ; then
70- : # do nothing
71+ echo " Already have it "
7172 elif dpkg -l google-cloud-cli 2> /dev/null | grep -q " ^ii" ; then
7273 # Check if apt package is already installed
7374 if dpkg -l google-cloud-cli-gke-gcloud-auth-plugin 2> /dev/null | grep -q " ^ii" ; then
74- : # do nothing
75+ echo " We have gcloud installed via apt "
7576 else
7677 echo " Installing GKE auth plugin for kubectl via apt..."
7778 sudo apt-get update
You can’t perform that action at this time.
0 commit comments