Skip to content

Commit

Permalink
fix: version update
Browse files Browse the repository at this point in the history
  • Loading branch information
Priyaccuknox authored Dec 18, 2024
1 parent 3f5b6ae commit 97db1ac
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 101 deletions.
37 changes: 22 additions & 15 deletions .github/workflows/action.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Accuknox-Job Workflow
name: KSPM-Runtime Workflow

on:
push:
Expand All @@ -9,6 +9,7 @@ on:
branches:
- "*"


jobs:
tag-validate:
runs-on: ubuntu-latest
Expand All @@ -20,6 +21,7 @@ jobs:

helm_chart_validation:
runs-on: ubuntu-latest
if: always() && !contains(needs.tag-validate.result, 'failure')
needs: [tag-validate]
steps:
- name: Checkout code
Expand All @@ -31,14 +33,19 @@ jobs:
chmod 700 get_helm.sh
./get_helm.sh
- name: Update Helm Dependencies
run: |
cd kspm-runtime
helm dependency update
- name: Validate Helm charts
run: |
helm lint accuknox-jobs
helm template accuknox-jobs --dry-run > /dev/null
helm lint kspm-runtime
helm template kspm-runtime --dry-run > /dev/null
helm_push_to_ecr:
runs-on: ubuntu-latest
needs: [helm_chart_validation,tag-validate]
needs: [helm_chart_validation]
steps:
- name: Checkout code
uses: actions/checkout@v2
Expand All @@ -60,19 +67,19 @@ jobs:
run: |
aws ecr-public get-login-password --region us-east-1 | helm registry login --username AWS --password-stdin ${{ secrets.REPO }}
- name: Update Helm Dependencies
run: |
cd kspm-runtime
helm dependency update
- name: Chart versioning
- name: Chart versioning
if: ( github.event_name != 'pull_request' && github.event_name != 'pull_request_target' )
shell: bash
id: chart-version
run: |
sed -i "s/^version:.*$/version: ${{ github.ref_name }}/" accuknox-jobs/Chart.yaml
sed -i "s/^appVersion:.*$/appVersion: ${{ github.ref_name }}/" accuknox-jobs/Chart.yaml
sed -i "s/^version:.*$/version: ${{ github.ref_name }}/" kspm-runtime/Chart.yaml
sed -i "s/^appVersion:.*$/appVersion: ${{ github.ref_name }}/" kspm-runtime/Chart.yaml
- name: Package and Push Helm Charts
- name: Package and Push Helm Chart
run: |
helm package accuknox-jobs
HELM_PACKAGE=$(ls accuknox-jobs-*.tgz)
helm push $HELM_PACKAGE oci://${{ secrets.REPO }}
helm package kspm-runtime
HELM_PACKAGE=$(ls kspm-runtime-*.tgz)
helm push $HELM_PACKAGE oci://${{ secrets.REPO }}
85 changes: 0 additions & 85 deletions .github/workflows/kspm-runtime.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion kspm-runtime/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dependencies:
repository: oci://registry-1.docker.io/accuknox
condition: accuknox-agents.enabled
- name: kubearmor
version: v1.4.3
version: v1.4.6
repository: https://kubearmor.github.io/charts
condition: kubearmor.enabled
- name: cis-k8s-job
Expand Down

0 comments on commit 97db1ac

Please sign in to comment.