Skip to content

Commit

Permalink
add kubeconfig mode
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-gilber committed Nov 6, 2023
1 parent 03a23e7 commit 0768d72
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,16 @@ jobs:
k3s_version: ['', v1.28.2+k3s1, v1.27.7+k3s1, v1.26.10+k3s1]
runs-on: ubuntu-latest
env:
K3S_KUBECONFIG: /etc/rancher/k3s/k3s.yaml
KUBECONFIG: /etc/rancher/k3s/k3s.yaml
steps:
- name: Setup k3s
run: |
curl -sfL https://get.k3s.io | INSTALL_K3S_VERSION=${{ matrix.k3s_version }} sh -
mkdir -p ~/.kube
sudo cp ${{ env.K3S_KUBECONFIG }} ~/.kube/config
chown $USER ~/.kube/config
chmod 600 ~/.kube/config
curl -sfL https://get.k3s.io | K3S_KUBECONFIG_MODE="644" INSTALL_K3S_VERSION=${{ matrix.k3s_version }} sh -
# mkdir -p ~/.kube
# sudo cp ${{ env.K3S_KUBECONFIG }} ~/.kube/config
# chown $USER ~/.kube/config
# chown $USER ${{ env.KUBECONFIG }}
# chmod 600 ${{ env.KUBECONFIG }}
# Kubectl is pre-installed in GitHub-hosted runners: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2204-Readme.md#tools
- name: Get Version and Nodes
Expand Down

0 comments on commit 0768d72

Please sign in to comment.