Skip to content

feat: add keycloak instance to helm chart #288

feat: add keycloak instance to helm chart

feat: add keycloak instance to helm chart #288

Workflow file for this run

#################################################################################
# Eclipse Tractus-X - Industry Core Hub Frontend
#
# Copyright (c) 2025 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
#
# This program and the accompanying materials are made available under the
# terms of the Apache License, Version 2.0 which is available at
# https://www.apache.org/licenses/LICENSE-2.0.
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
# either express or implied. See the
# License for the specific language govern in permissions and limitations
# under the License.
#
# SPDX-License-Identifier: Apache-2.0
#################################################################################
name: Lint and Test Charts
on:
push:
paths:
- "charts/industry-core-hub/**"
branches:
- main
pull_request:
paths:
- "charts/industry-core-hub/**"
branches:
- main
workflow_dispatch:
inputs:
node_image:
description: "kindest/node image for k8s kind cluster"
# k8s version from 3.1 release as default
default: "kindest/node:v1.27.3"
required: false
type: string
upgrade_from:
description: "chart version to upgrade from"
default: "0.1.3"
required: false
type: string
helm_version:
description: "helm version to test (default = latest)"
default: "latest"
required: false
type: string
jobs:
lint-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- name: Kubernetes KinD Cluster
uses: container-tools/kind-action@0ad70e2299366b0e1552c7240f4e4567148f723e # v2.0.4
with:
# upgrade version, default (v0.17.0) uses node image v1.21.1 and doesn't work with more recent node image versions
version: v0.20.0
# default value for event_name != workflow_dispatch
node_image: ${{ github.event.inputs.node_image || 'kindest/node:v1.27.3' }}
- name: Set up Helm
uses: azure/setup-helm@fe7b79cd5ee1e45176fcad797de68ecaf3ca4814 # v4
with:
version: ${{ github.event.inputs.helm_version || 'latest' }}
- uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: "3.9"
check-latest: true
- name: Set up chart-testing
uses: helm/chart-testing-action@0d28d3144d3a25ea2cc349d6e59901c4ff469b3b # v2.7.0
- name: Run chart-testing (list-changed)
id: list-changed
run: |
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }})
if [[ -n "$changed" ]]; then
echo "changed=true" >> $GITHUB_OUTPUT
fi
- name: Run chart-testing (lint)
run: ct lint --validate-maintainers=false --target-branch ${{ github.event.repository.default_branch }}
- name: Setup Helm repos
run: |
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add bitnami-full-index https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
helm repo add runix https://helm.runix.net
- name: Run chart-testing (install)
run: ct install --charts charts/industry-core-hub --target-branch ${{ github.event.repository.default_branch }}
if: github.event_name != 'pull_request' || steps.list-changed.outputs.changed == 'true'
# Upgrade the released chart version with the locally available chart
- name: Run helm upgrade
run: |
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add bitnami-full-index https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
helm repo add runix https://helm.runix.net
helm repo add tractusx-dev https://eclipse-tractusx.github.io/charts/dev
helm install industry-core-hub tractusx-dev/industry-core-hub --version ${{ github.event.inputs.upgrade_from || 'x.x.x' }}
helm dependency update charts/industry-core-hub
helm upgrade industry-core-hub charts/industry-core-hub
if: github.event_name != 'pull_request' || steps.list-changed.outputs.changed == 'true'