Skip to content

kie-issues#1214: Replace explicit references to quay.io images across CI pipelines #3317

kie-issues#1214: Replace explicit references to quay.io images across CI pipelines

kie-issues#1214: Replace explicit references to quay.io images across CI pipelines #3317

#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://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 governing permissions and limitations
# under the License.
#
name: Images PR check
on: pull_request
jobs:
bats_test:
concurrency:
group: ${{ github.repository.name }}_bats_test-${{ github.head_ref }}
cancel-in-progress: true
name: Bats Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install xmllint
run: |
sudo apt-get update &&\
sudo apt-get -y install --no-install-recommends --fix-missing \
libxml2-utils
- name: Cache bats binaries
uses: actions/cache@v1
with:
path: $GITHUB_WORKSPACE/bats/
key: ${{ runner.os }}-bats-binaries
restore-keys: |
${{ runner.os }}-bats-binaries
- name: run bats
run: |
./scripts/run-bats.sh
validate_kogito_imagestream:
concurrency:
group: ${{ github.repository.name }}_validate_kogito_imagestream-${{ github.head_ref }}
cancel-in-progress: true
name: Validate Kogito imagestreams
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download openshift-validator-tool
run: |
wget https://github.com/jboss-container-images/jboss-kie-modules/raw/main/tools/openshift-template-validator/openshift-template-validator-linux-amd64
- name: Add execution permission to openshift-validator-tool
run: |
chmod +x openshift-template-validator-linux-amd64
mv openshift-template-validator-linux-amd64 ${HOME}
- name: validate kogito imagestream
run: |
${HOME}/openshift-template-validator-linux-amd64 validate -f kogito-imagestream.yaml
shellcheck:
concurrency:
group: ${{ github.repository.name }}_shellcheck-${{ github.head_ref }}
cancel-in-progress: true
name: ShellCheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Shellcheck
run: |
sudo apt-get update &&\
sudo apt-get -y install --no-install-recommends \
shellcheck
- name: Check configure scripts
run: |
# Ignore SC2034 since we have many var which are unused in the script but can be used while deployment at runtime by setting env. For eg: ${KOGITO_QUARKUS_JVM_PROPS}
# Ignore SC1090 since the source files in our case didn't need to be checked
shopt -s globstar nullglob
shellcheck -e SC2034 -e SC1090 -S warning modules/**/configure modules/**/*.sh