Bump mikefarah/yq from 4.40.7 to 4.41.1 #394
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pull Request | |
on: | |
pull_request: | |
branches: | |
- master | |
paths-ignore: | |
- '**.md' | |
- 'stable/hazelcast-platform-operator' | |
pull_request_target: | |
types: [labeled] | |
branches: | |
- master | |
paths-ignore: | |
- '**.md' | |
permissions: | |
contents: read | |
jobs: | |
tests: | |
if: >- | |
(github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name,'safe-to-test') && github.event.pull_request.head.repo.full_name != github.repository) || | |
(github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) | |
name: Run tests | |
runs-on: ubuntu-20.04 | |
env: | |
KUBECTL_VERSION: 1.22.0 | |
AWS_REGION: us-east-1 | |
steps: | |
- name: Decide which ref to checkout | |
id: decide-ref | |
run: | | |
if [[ "${{github.event_name}}" == "pull_request" ]]; then | |
echo "::set-output name=ref::${{github.ref}}" | |
else | |
echo "::set-output name=ref::refs/pull/${{ github.event.pull_request.number }}/merge" | |
fi | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{steps.decide-ref.outputs.ref}} | |
fetch-depth: 0 | |
- name: Add remote hazelcast | |
run: | | |
git remote add hazelcast https://github.com/hazelcast/charts.git | |
git fetch hazelcast master | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
aws-region: ${{ env.AWS_REGION }} | |
- name: Get Secrets | |
uses: aws-actions/aws-secretsmanager-get-secrets@v2 | |
with: | |
secret-ids: | | |
HZ_LICENSE_KEY,CN/HZ_LICENSE_KEY | |
- name: Set up Helm | |
uses: azure/setup-helm@v3.5 | |
with: | |
version: v3.10.3 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: 3.7 | |
- name: Set up chart-testing | |
uses: helm/chart-testing-action@v2.6.1 | |
- name: Add values.yaml for testing | |
run: | | |
MODIFIED_CHARTS=( $(ct list-changed --config ${GITHUB_WORKSPACE}/test/ct.yaml ) ) | |
for chart in "${MODIFIED_CHARTS[@]}" | |
do | |
if [ $chart == "stable/hazelcast" ]; then | |
mkdir -p ${GITHUB_WORKSPACE}/stable/hazelcast/ci | |
cat << EOF > ${GITHUB_WORKSPACE}/stable/hazelcast/ci/gha_gke-values.yaml | |
mancenter: | |
licenseKey: ${{ env.HZ_LICENSE_KEY }} | |
devMode: | |
enabled: true | |
javaOpts: "-Dhazelcast.mc.rest.enabled=true" | |
EOF | |
fi | |
if [ $chart == "stable/hazelcast-enterprise" ]; then | |
mkdir -p ${GITHUB_WORKSPACE}/stable/hazelcast-enterprise/ci | |
cat << EOF > ${GITHUB_WORKSPACE}/stable/hazelcast-enterprise/ci/gha_gke-values.yaml | |
hazelcast: | |
licenseKey: ${{ env.HZ_LICENSE_KEY }} | |
mancenter: | |
devMode: | |
enabled: true | |
javaOpts: "-Dhazelcast.mc.rest.enabled=true" | |
EOF | |
fi | |
done | |
- name: Lint Charts | |
run: | | |
ct lint --config ${GITHUB_WORKSPACE}/test/ct.yaml | |
- name: Create Kind Config | |
run: | | |
cat <<EOT >> ./kind-config.yaml | |
kind: Cluster | |
apiVersion: kind.x-k8s.io/v1alpha4 | |
nodes: | |
- role: control-plane | |
- role: worker | |
- role: worker | |
- role: worker | |
EOT | |
- name: Create Kind Cluster | |
uses: helm/kind-action@v1.9.0 | |
with: | |
config: ./kind-config.yaml | |
cluster_name: kind | |
- name: Test Charts | |
run: | | |
ct install --config ${GITHUB_WORKSPACE}/test/ct.yaml |