Skip to content

Commit

Permalink
helm install dry-run to k3s
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-gilber committed Nov 6, 2023
1 parent 0768d72 commit 8182435
Showing 1 changed file with 12 additions and 27 deletions.
39 changes: 12 additions & 27 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,49 +36,34 @@ jobs:
chart: [demoapp-backend, demoapp-frontend]
value: [values.yaml]
# k3s releases: https://github.com/k3s-io/k3s/releases
# '' = stable version
k3s_version: ['', v1.28.2+k3s1, v1.27.7+k3s1, v1.26.10+k3s1]
runs-on: ubuntu-latest
env:
# Set KUBECONFIG path to default k3s location
KUBECONFIG: /etc/rancher/k3s/k3s.yaml
steps:
- name: Setup k3s
run: |
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
run: |
ls -la ${{ env.KUBECONFIG }}
kubectl version
kubectl get nodes
# - name: Checkout repository
# uses: actions/checkout@v4 # https://github.com/marketplace/actions/checkout
# - name: Dry-run k3s
# run: |
# cd "${{env.CHARTS_ROOT}}/${{ matrix.chart }}"
# helm dependency update .
# helm template . --values "${{ matrix.value }}"

helm-dry-run-kubernetes:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4 # https://github.com/marketplace/actions/checkout

helm-deploy-k3s:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4 # https://github.com/marketplace/actions/checkout
- name: Dry-run k3s
run: |
cd "${{env.CHARTS_ROOT}}/${{ matrix.chart }}"
helm dependency update .
helm install ${{ matrix.chart }} . --dry-run=server
helm-dry-run-openshift:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4 # https://github.com/marketplace/actions/checkout
# helm-dry-run-openshift:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout repository
# uses: actions/checkout@v4 # https://github.com/marketplace/actions/checkout

0 comments on commit 8182435

Please sign in to comment.